diff --git a/CTFd/api/v1/files.py b/CTFd/api/v1/files.py index 7e31ae7b9898db799a9dc385cfcb38c2df17979a..0a042fee6765040b034f3044159c79a20f1a1f35 100644 --- a/CTFd/api/v1/files.py +++ b/CTFd/api/v1/files.py @@ -284,3 +284,70 @@ class FilesDetail(Resource): db.session.close() return {"success": True} + +@files_namespace.route("/old") +class FilesList(Resource): + @admins_only + @files_namespace.doc( + description="Endpoint to get file objects in bulk", + responses={ + 200: ("Success", "FileDetailedSuccessResponse"), + 400: ( + "An error occured processing the provided or stored data", + "APISimpleErrorResponse", + ), + }, + params={ + "file": { + "in": "formData", + "type": "file", + "required": True, + "description": "The file to upload", + } + }, + ) + @validate_args( + { + "challenge_id": (int, None), + "challenge": (int, None), + "page_id": (int, None), + "page": (int, None), + "type": (str, None), + "location": (str, None), + }, + location="form", + ) + def post(self, form_args): + files = request.files.getlist("file") + location = form_args.get("location") + # challenge_id + # page_id + + # Handle situation where users attempt to upload multiple files with a single location + if len(files) > 1 and location: + return { + "success": False, + "errors": { + "location": ["Location cannot be specified with multiple files"] + }, + }, 400 + + objs = [] + for f in files: + # uploads.upload_file(file=f, chalid=req.get('challenge')) + try: + obj = uploads.upload_file(file=f, **form_args) + except ValueError as e: + return { + "success": False, + "errors": {"location": [str(e)]}, + }, 400 + objs.append(obj) + + schema = FileSchema(many=True) + response = schema.dump(objs) + + if response.errors: + return {"success": False, "errors": response.errors}, 400 + + return {"success": True, "data": response.data} \ No newline at end of file diff --git a/CTFd/themes/admin/assets/js/compat/helpers.js b/CTFd/themes/admin/assets/js/compat/helpers.js index 48e5384382e4b7e8984df4d3c09081503cbefb1f..66bf2de04a9806e60923436a5a6bf08773459394 100644 --- a/CTFd/themes/admin/assets/js/compat/helpers.js +++ b/CTFd/themes/admin/assets/js/compat/helpers.js @@ -12,7 +12,7 @@ const utils = { }; const files = { - upload: (formData, extra_data, cb) => { + upload: (formData, extra_data, cb, old=false) => { const CTFd = window.CTFd; try { if (formData instanceof jQuery) { @@ -41,8 +41,10 @@ const files = { width: 0, title: "Progrès de l'envoi", }); + var apiPath = old ? "/api/v1/files/old?admin=true" : "/api/v1/files?admin=true" + console.log(old); $.ajax({ - url: CTFd.config.urlRoot + "/api/v1/files?admin=true", + url: CTFd.config.urlRoot + apiPath, data: formData, type: "POST", cache: false, diff --git a/CTFd/themes/admin/assets/js/components/files/ChallengeFilesList.vue b/CTFd/themes/admin/assets/js/components/files/ChallengeFilesList.vue index 093793b7236e03494d91f5fb0a8dad51d081f001..6c44e519559d6b2628c7c00235de6761e694e999 100644 --- a/CTFd/themes/admin/assets/js/components/files/ChallengeFilesList.vue +++ b/CTFd/themes/admin/assets/js/components/files/ChallengeFilesList.vue @@ -1,5 +1,5 @@ <template> - <div> + <div style="max-width: 50vw;"> <table id="filesboard" class="table table-striped"> <thead> <tr> @@ -11,7 +11,9 @@ <tr v-for="file in files" :key="file.id"> <td class="text-center"> <a :href="`${urlRoot}/files/${file.location}`">{{ - file.location.split("/").pop() + file.location.split("/").pop().length > 30 + ? file.location.split("/").pop().slice(0, 30) + "..." + : file.location.split("/").pop() }}</a> </td> @@ -90,11 +92,12 @@ export default { type: "challenge", }; let form = this.$refs.FileUploadForm; + console.log("HELLODSDG"); helpers.files.upload(form, data, (_response) => { setTimeout(() => { this.loadFiles(); }, 700); - }); + }, true); }, deleteFile: function (fileId) { ezQuery({ diff --git a/CTFd/themes/admin/static/assets/CommentBox.d08ed1e6.js b/CTFd/themes/admin/static/assets/CommentBox.f5ce8d13.js similarity index 98% rename from CTFd/themes/admin/static/assets/CommentBox.d08ed1e6.js rename to CTFd/themes/admin/static/assets/CommentBox.f5ce8d13.js index 356630fe038f59c262aaf459d3959d4e9dbb93ca..37dc382547e7f05281da4866c36035718151fed2 100644 --- a/CTFd/themes/admin/static/assets/CommentBox.d08ed1e6.js +++ b/CTFd/themes/admin/static/assets/CommentBox.f5ce8d13.js @@ -1 +1 @@ -import{_ as r,C as u,I as h,s as m,J as p,c as l,a as e,h as _,l as g,t as a,b as c,f as b,g as v,T as f,o as d,F as C,r as y,p as k,k as x}from"./pages/main.9b987665.js";const $={props:{type:String,id:Number},data:function(){return{page:1,pages:null,next:null,prev:null,total:null,comment:"",comments:[],urlRoot:u.config.urlRoot}},methods:{toLocalTime(t){return h(t).format("MMMM Do, h:mm:ss A")},nextPage:function(){this.page++,this.loadComments()},prevPage:function(){this.page--,this.loadComments()},getArgs:function(){let t={};return t[`${this.$props.type}_id`]=this.$props.id,t},loadComments:function(){let t=this.getArgs();t.page=this.page,t.per_page=10,m.comments.get_comments(t).then(s=>(this.page=s.meta.pagination.page,this.pages=s.meta.pagination.pages,this.next=s.meta.pagination.next,this.prev=s.meta.pagination.prev,this.total=s.meta.pagination.total,this.comments=s.data,this.comments))},submitComment:function(){let t=this.comment.trim();t.length>0&&m.comments.add_comment(t,this.$props.type,this.getArgs(),()=>{this.loadComments()}),this.comment=""},deleteComment:function(t){confirm("Are you sure you'd like to delete this comment?")&&m.comments.delete_comment(t).then(s=>{if(s.success===!0)for(let i=this.comments.length-1;i>=0;--i)this.comments[i].id==t&&this.comments.splice(i,1)})}},created(){this.loadComments()},updated(){this.$el.querySelectorAll("pre code").forEach(t=>{p.highlightBlock(t)})}},A=t=>(k("data-v-53a121d7"),t=t(),x(),t),P={class:"row mb-3"},T={class:"col-md-12"},w={class:"comment"},M={key:0,class:"row"},S={class:"col-md-12"},B={class:"text-center"},L=["disabled"],I=["disabled"],N={class:"col-md-12"},V={class:"text-center"},D={class:"text-muted"},F={class:"comments"},H={class:"card-body pl-0 pb-0 pt-2 pr-2"},R=["onClick"],j=A(()=>e("span",{"aria-hidden":"true"},"\xD7",-1)),E=[j],J={class:"card-body"},q=["innerHTML"],z={class:"text-muted float-left"},G=["href"],U={class:"text-muted float-right"},K={class:"float-right"},O={key:1,class:"row"},Q={class:"col-md-12"},W={class:"text-center"},X=["disabled"],Y=["disabled"],Z={class:"col-md-12"},tt={class:"text-center"},et={class:"text-muted"};function st(t,s,i,ot,nt,n){return d(),l("div",null,[e("div",P,[e("div",T,[e("div",w,[_(e("textarea",{class:"form-control mb-2",rows:"2",id:"comment-input",placeholder:"Ajouter un commentaire","onUpdate:modelValue":s[0]||(s[0]=o=>t.comment=o)},null,512),[[g,t.comment,void 0,{lazy:!0}]]),e("button",{class:"btn btn-sm btn-primary btn-outlined float-right",type:"submit",onClick:s[1]||(s[1]=o=>n.submitComment())}," Comment ")])])]),t.pages>1?(d(),l("div",M,[e("div",S,[e("div",B,[e("button",{type:"button",class:"btn btn-link p-0",onClick:s[2]||(s[2]=o=>n.prevPage()),disabled:!t.prev}," <<< ",8,L),e("button",{type:"button",class:"btn btn-link p-0",onClick:s[3]||(s[3]=o=>n.nextPage()),disabled:!t.next}," >>> ",8,I)])]),e("div",N,[e("div",V,[e("small",D,"Page "+a(t.page)+" de "+a(t.total)+" comments",1)])])])):c("",!0),e("div",F,[b(f,{name:"comment-card"},{default:v(()=>[(d(!0),l(C,null,y(t.comments,o=>(d(),l("div",{class:"comment-card card mb-2",key:o.id},[e("div",H,[e("button",{type:"button",class:"close float-right","aria-label":"Close",onClick:at=>n.deleteComment(o.id)},E,8,R)]),e("div",J,[e("div",{class:"card-text",innerHTML:o.html},null,8,q),e("small",z,[e("span",null,[e("a",{href:`${t.urlRoot}/admin/users/${o.author_id}`},a(o.author.name),9,G)])]),e("small",U,[e("span",K,a(n.toLocalTime(o.date)),1)])])]))),128))]),_:1})]),t.pages>1?(d(),l("div",O,[e("div",Q,[e("div",W,[e("button",{type:"button",class:"btn btn-link p-0",onClick:s[4]||(s[4]=o=>n.prevPage()),disabled:!t.prev}," <<< ",8,X),e("button",{type:"button",class:"btn btn-link p-0",onClick:s[5]||(s[5]=o=>n.nextPage()),disabled:!t.next}," >>> ",8,Y)])]),e("div",Z,[e("div",tt,[e("small",et,"Page "+a(t.page)+" de "+a(t.total)+" comments",1)])])])):c("",!0)])}const lt=r($,[["render",st],["__scopeId","data-v-53a121d7"]]);export{lt as C}; +import{_ as r,C as u,I as h,s as m,J as p,c as l,a as e,h as _,l as g,t as a,b as c,f as b,g as v,T as f,o as d,F as C,r as y,p as k,k as x}from"./pages/main.71d0edc5.js";const $={props:{type:String,id:Number},data:function(){return{page:1,pages:null,next:null,prev:null,total:null,comment:"",comments:[],urlRoot:u.config.urlRoot}},methods:{toLocalTime(t){return h(t).format("MMMM Do, h:mm:ss A")},nextPage:function(){this.page++,this.loadComments()},prevPage:function(){this.page--,this.loadComments()},getArgs:function(){let t={};return t[`${this.$props.type}_id`]=this.$props.id,t},loadComments:function(){let t=this.getArgs();t.page=this.page,t.per_page=10,m.comments.get_comments(t).then(s=>(this.page=s.meta.pagination.page,this.pages=s.meta.pagination.pages,this.next=s.meta.pagination.next,this.prev=s.meta.pagination.prev,this.total=s.meta.pagination.total,this.comments=s.data,this.comments))},submitComment:function(){let t=this.comment.trim();t.length>0&&m.comments.add_comment(t,this.$props.type,this.getArgs(),()=>{this.loadComments()}),this.comment=""},deleteComment:function(t){confirm("Are you sure you'd like to delete this comment?")&&m.comments.delete_comment(t).then(s=>{if(s.success===!0)for(let i=this.comments.length-1;i>=0;--i)this.comments[i].id==t&&this.comments.splice(i,1)})}},created(){this.loadComments()},updated(){this.$el.querySelectorAll("pre code").forEach(t=>{p.highlightBlock(t)})}},A=t=>(k("data-v-53a121d7"),t=t(),x(),t),P={class:"row mb-3"},T={class:"col-md-12"},w={class:"comment"},M={key:0,class:"row"},S={class:"col-md-12"},B={class:"text-center"},L=["disabled"],I=["disabled"],N={class:"col-md-12"},V={class:"text-center"},D={class:"text-muted"},F={class:"comments"},H={class:"card-body pl-0 pb-0 pt-2 pr-2"},R=["onClick"],j=A(()=>e("span",{"aria-hidden":"true"},"\xD7",-1)),E=[j],J={class:"card-body"},q=["innerHTML"],z={class:"text-muted float-left"},G=["href"],U={class:"text-muted float-right"},K={class:"float-right"},O={key:1,class:"row"},Q={class:"col-md-12"},W={class:"text-center"},X=["disabled"],Y=["disabled"],Z={class:"col-md-12"},tt={class:"text-center"},et={class:"text-muted"};function st(t,s,i,ot,nt,n){return d(),l("div",null,[e("div",P,[e("div",T,[e("div",w,[_(e("textarea",{class:"form-control mb-2",rows:"2",id:"comment-input",placeholder:"Ajouter un commentaire","onUpdate:modelValue":s[0]||(s[0]=o=>t.comment=o)},null,512),[[g,t.comment,void 0,{lazy:!0}]]),e("button",{class:"btn btn-sm btn-primary btn-outlined float-right",type:"submit",onClick:s[1]||(s[1]=o=>n.submitComment())}," Comment ")])])]),t.pages>1?(d(),l("div",M,[e("div",S,[e("div",B,[e("button",{type:"button",class:"btn btn-link p-0",onClick:s[2]||(s[2]=o=>n.prevPage()),disabled:!t.prev}," <<< ",8,L),e("button",{type:"button",class:"btn btn-link p-0",onClick:s[3]||(s[3]=o=>n.nextPage()),disabled:!t.next}," >>> ",8,I)])]),e("div",N,[e("div",V,[e("small",D,"Page "+a(t.page)+" de "+a(t.total)+" comments",1)])])])):c("",!0),e("div",F,[b(f,{name:"comment-card"},{default:v(()=>[(d(!0),l(C,null,y(t.comments,o=>(d(),l("div",{class:"comment-card card mb-2",key:o.id},[e("div",H,[e("button",{type:"button",class:"close float-right","aria-label":"Close",onClick:at=>n.deleteComment(o.id)},E,8,R)]),e("div",J,[e("div",{class:"card-text",innerHTML:o.html},null,8,q),e("small",z,[e("span",null,[e("a",{href:`${t.urlRoot}/admin/users/${o.author_id}`},a(o.author.name),9,G)])]),e("small",U,[e("span",K,a(n.toLocalTime(o.date)),1)])])]))),128))]),_:1})]),t.pages>1?(d(),l("div",O,[e("div",Q,[e("div",W,[e("button",{type:"button",class:"btn btn-link p-0",onClick:s[4]||(s[4]=o=>n.prevPage()),disabled:!t.prev}," <<< ",8,X),e("button",{type:"button",class:"btn btn-link p-0",onClick:s[5]||(s[5]=o=>n.nextPage()),disabled:!t.next}," >>> ",8,Y)])]),e("div",Z,[e("div",tt,[e("small",et,"Page "+a(t.page)+" de "+a(t.total)+" comments",1)])])])):c("",!0)])}const lt=r($,[["render",st],["__scopeId","data-v-53a121d7"]]);export{lt as C}; diff --git a/CTFd/themes/admin/static/assets/echarts.common.e43059b8.js b/CTFd/themes/admin/static/assets/echarts.common.a0aaa3a0.js similarity index 99% rename from CTFd/themes/admin/static/assets/echarts.common.e43059b8.js rename to CTFd/themes/admin/static/assets/echarts.common.a0aaa3a0.js index a7f66122e0b7812e973f50a74518ae2bfcdf6105..6203d070a8491c5cd899dac4fe7fa6992f8f4d70 100644 --- a/CTFd/themes/admin/static/assets/echarts.common.e43059b8.js +++ b/CTFd/themes/admin/static/assets/echarts.common.a0aaa3a0.js @@ -1,4 +1,4 @@ -import{O as DB,H as dw}from"./pages/main.9b987665.js";var Dd={exports:{}};(function(IB,pw){(function(U,Ji){Ji(pw)})(dw,function(U){/*! ***************************************************************************** +import{O as DB,H as dw}from"./pages/main.71d0edc5.js";var Dd={exports:{}};(function(IB,pw){(function(U,Ji){Ji(pw)})(dw,function(U){/*! ***************************************************************************** Copyright (c) Microsoft Corporation. Permission to use, copy, modify, and/or distribute this software for any diff --git a/CTFd/themes/admin/static/assets/graphs.10b6af37.js b/CTFd/themes/admin/static/assets/graphs.253aebe5.js similarity index 96% rename from CTFd/themes/admin/static/assets/graphs.10b6af37.js rename to CTFd/themes/admin/static/assets/graphs.253aebe5.js index 869a360689325077c21eaecdf352da66345d4a7a..da36db6080946a890f05e2518540b2dc19dee553 100644 --- a/CTFd/themes/admin/static/assets/graphs.10b6af37.js +++ b/CTFd/themes/admin/static/assets/graphs.253aebe5.js @@ -1 +1 @@ -import{$ as g,I as y,N as f}from"./pages/main.9b987665.js";import{e as h}from"./echarts.common.e43059b8.js";function b(c){let i=c.concat();for(let a=0;a<c.length;a++)i[a]=c.slice(0,a+1).reduce(function(u,r){return u+r});return i}const m={score_graph:{format:(c,i,a,u,r)=>{let n={title:{left:"center",text:"Score dans le temps"},tooltip:{trigger:"axis",axisPointer:{type:"cross"}},legend:{type:"scroll",orient:"horizontal",align:"left",bottom:0,data:[a]},toolbox:{feature:{saveAsImage:{}}},grid:{containLabel:!0},xAxis:[{type:"category",boundaryGap:!1,data:[]}],yAxis:[{type:"value"}],dataZoom:[{id:"dataZoomX",type:"slider",xAxisIndex:[0],filterMode:"filter",height:20,top:35,fillerColor:"rgba(233, 236, 241, 0.4)"}],series:[]};const s=[],l=[],o=r[0].data,d=r[2].data,e=o.concat(d);e.sort((t,p)=>new Date(t.date)-new Date(p.date));for(let t=0;t<e.length;t++){const p=y(e[t].date);s.push(p.toDate());try{l.push(e[t].challenge.value)}catch{l.push(e[t].value)}}return s.forEach(t=>{n.xAxis[0].data.push(t)}),n.series.push({name:window.stats_data.name,type:"line",label:{normal:{show:!0,position:"top"}},areaStyle:{normal:{color:f(a+i)}},itemStyle:{normal:{color:f(a+i)}},data:b(l)}),n}},category_breakdown:{format:(c,i,a,u,r)=>{let n={title:{left:"center",text:"R\xE9partition des cat\xE9gories"},tooltip:{trigger:"item"},toolbox:{show:!0,feature:{saveAsImage:{}}},legend:{type:"scroll",orient:"vertical",top:"middle",right:0,data:[]},series:[{name:"R\xE9partition des cat\xE9gories",type:"pie",radius:["30%","50%"],avoidLabelOverlap:!1,label:{show:!1,position:"center"},itemStyle:{normal:{label:{show:!0,formatter:function(e){return`${e.percent}% (${e.value})`}},labelLine:{show:!0}},emphasis:{label:{show:!0,position:"center",textStyle:{fontSize:"14",fontWeight:"normal"}}}},emphasis:{label:{show:!0,fontSize:"30",fontWeight:"bold"}},labelLine:{show:!1},data:[]}]};const s=r[0].data,l=[];for(let e=0;e<s.length;e++)l.push(s[e].challenge.category);const o=l.filter((e,t)=>l.indexOf(e)==t),d=[];for(let e=0;e<o.length;e++){let t=0;for(let p=0;p<l.length;p++)l[p]==o[e]&&t++;d.push(t)}return o.forEach((e,t)=>{n.legend.data.push(e),n.series[0].data.push({value:d[t],name:e,itemStyle:{color:f(e)}})}),n}},solve_percentages:{format:(c,i,a,u,r)=>{const n=r[0].data.length,s=r[1].meta.count;return{title:{left:"center",text:"Pourcentage de r\xE9solution"},tooltip:{trigger:"item"},toolbox:{show:!0,feature:{saveAsImage:{}}},legend:{orient:"vertical",top:"middle",right:0,data:["Fails","Solves"]},series:[{name:"Pourcentage de r\xE9solution",type:"pie",radius:["30%","50%"],avoidLabelOverlap:!1,label:{show:!1,position:"center"},itemStyle:{normal:{label:{show:!0,formatter:function(o){return`${o.name} - ${o.value} (${o.percent}%)`}},labelLine:{show:!0}},emphasis:{label:{show:!0,position:"center",textStyle:{fontSize:"14",fontWeight:"normal"}}}},emphasis:{label:{show:!0,fontSize:"30",fontWeight:"bold"}},labelLine:{show:!1},data:[{value:s,name:"Fails",itemStyle:{color:"rgb(207, 38, 0)"}},{value:n,name:"Solves",itemStyle:{color:"rgb(0, 209, 64)"}}]}]}}}};function S(c,i,a,u,r,n,s){const l=m[c];let o=h.init(document.querySelector(i));o.setOption(l.format(u,r,n,s,a)),g(window).on("resize",function(){o!=null&&o!=null&&o.resize()})}function _(c,i,a,u,r,n,s){const l=m[c];h.init(document.querySelector(i)).setOption(l.format(u,r,n,s,a))}export{S as c,_ as u}; +import{$ as g,I as y,N as f}from"./pages/main.71d0edc5.js";import{e as h}from"./echarts.common.a0aaa3a0.js";function b(c){let i=c.concat();for(let a=0;a<c.length;a++)i[a]=c.slice(0,a+1).reduce(function(u,r){return u+r});return i}const m={score_graph:{format:(c,i,a,u,r)=>{let n={title:{left:"center",text:"Score dans le temps"},tooltip:{trigger:"axis",axisPointer:{type:"cross"}},legend:{type:"scroll",orient:"horizontal",align:"left",bottom:0,data:[a]},toolbox:{feature:{saveAsImage:{}}},grid:{containLabel:!0},xAxis:[{type:"category",boundaryGap:!1,data:[]}],yAxis:[{type:"value"}],dataZoom:[{id:"dataZoomX",type:"slider",xAxisIndex:[0],filterMode:"filter",height:20,top:35,fillerColor:"rgba(233, 236, 241, 0.4)"}],series:[]};const s=[],l=[],o=r[0].data,d=r[2].data,e=o.concat(d);e.sort((t,p)=>new Date(t.date)-new Date(p.date));for(let t=0;t<e.length;t++){const p=y(e[t].date);s.push(p.toDate());try{l.push(e[t].challenge.value)}catch{l.push(e[t].value)}}return s.forEach(t=>{n.xAxis[0].data.push(t)}),n.series.push({name:window.stats_data.name,type:"line",label:{normal:{show:!0,position:"top"}},areaStyle:{normal:{color:f(a+i)}},itemStyle:{normal:{color:f(a+i)}},data:b(l)}),n}},category_breakdown:{format:(c,i,a,u,r)=>{let n={title:{left:"center",text:"R\xE9partition des cat\xE9gories"},tooltip:{trigger:"item"},toolbox:{show:!0,feature:{saveAsImage:{}}},legend:{type:"scroll",orient:"vertical",top:"middle",right:0,data:[]},series:[{name:"R\xE9partition des cat\xE9gories",type:"pie",radius:["30%","50%"],avoidLabelOverlap:!1,label:{show:!1,position:"center"},itemStyle:{normal:{label:{show:!0,formatter:function(e){return`${e.percent}% (${e.value})`}},labelLine:{show:!0}},emphasis:{label:{show:!0,position:"center",textStyle:{fontSize:"14",fontWeight:"normal"}}}},emphasis:{label:{show:!0,fontSize:"30",fontWeight:"bold"}},labelLine:{show:!1},data:[]}]};const s=r[0].data,l=[];for(let e=0;e<s.length;e++)l.push(s[e].challenge.category);const o=l.filter((e,t)=>l.indexOf(e)==t),d=[];for(let e=0;e<o.length;e++){let t=0;for(let p=0;p<l.length;p++)l[p]==o[e]&&t++;d.push(t)}return o.forEach((e,t)=>{n.legend.data.push(e),n.series[0].data.push({value:d[t],name:e,itemStyle:{color:f(e)}})}),n}},solve_percentages:{format:(c,i,a,u,r)=>{const n=r[0].data.length,s=r[1].meta.count;return{title:{left:"center",text:"Pourcentage de r\xE9solution"},tooltip:{trigger:"item"},toolbox:{show:!0,feature:{saveAsImage:{}}},legend:{orient:"vertical",top:"middle",right:0,data:["Fails","Solves"]},series:[{name:"Pourcentage de r\xE9solution",type:"pie",radius:["30%","50%"],avoidLabelOverlap:!1,label:{show:!1,position:"center"},itemStyle:{normal:{label:{show:!0,formatter:function(o){return`${o.name} - ${o.value} (${o.percent}%)`}},labelLine:{show:!0}},emphasis:{label:{show:!0,position:"center",textStyle:{fontSize:"14",fontWeight:"normal"}}}},emphasis:{label:{show:!0,fontSize:"30",fontWeight:"bold"}},labelLine:{show:!1},data:[{value:s,name:"Fails",itemStyle:{color:"rgb(207, 38, 0)"}},{value:n,name:"Solves",itemStyle:{color:"rgb(0, 209, 64)"}}]}]}}}};function S(c,i,a,u,r,n,s){const l=m[c];let o=h.init(document.querySelector(i));o.setOption(l.format(u,r,n,s,a)),g(window).on("resize",function(){o!=null&&o!=null&&o.resize()})}function _(c,i,a,u,r,n,s){const l=m[c];h.init(document.querySelector(i)).setOption(l.format(u,r,n,s,a))}export{S as c,_ as u}; diff --git a/CTFd/themes/admin/static/assets/htmlmixed.abcfee66.js b/CTFd/themes/admin/static/assets/htmlmixed.e85df030.js similarity index 99% rename from CTFd/themes/admin/static/assets/htmlmixed.abcfee66.js rename to CTFd/themes/admin/static/assets/htmlmixed.e85df030.js index c6f97533cfafea78fff9441f7b6035520d19a6b5..98c7f23165ffe39ec7b0137b1bf1eae887c93915 100644 --- a/CTFd/themes/admin/static/assets/htmlmixed.abcfee66.js +++ b/CTFd/themes/admin/static/assets/htmlmixed.e85df030.js @@ -1,4 +1,4 @@ -import{H as pu}from"./pages/main.9b987665.js";var lo={exports:{}},sa;function An(){return sa||(sa=1,function(Zr,Dn){(function(F,We){Zr.exports=We()})(pu,function(){var F=navigator.userAgent,We=navigator.platform,pe=/gecko\/\d/i.test(F),Je=/MSIE \d/.test(F),dt=/Trident\/(?:[7-9]|\d{2,})\..*rv:(\d+)/.exec(F),Pe=/Edge\/(\d+)/.exec(F),P=Je||dt||Pe,I=P&&(Je?document.documentMode||6:+(Pe||dt)[1]),se=!Pe&&/WebKit\//.test(F),re=se&&/Qt\/\d+\.\d+/.test(F),X=!Pe&&/Chrome\//.test(F),J=/Opera\//.test(F),fe=/Apple Computer/.test(navigator.vendor),Le=/Mac OS X 1\d\D([8-9]|\d\d)\D/.test(F),ze=/PhantomJS/.test(F),$=!Pe&&/AppleWebKit/.test(F)&&/Mobile\/\w+/.test(F),_e=/Android/.test(F),Q=$||_e||/webOS|BlackBerry|Opera Mini|Opera Mobi|IEMobile/i.test(F),Y=$||/Mac/.test(We),Te=/\bCrOS\b/.test(F),bt=/win/i.test(We),Ae=J&&F.match(/Version\/(\d*\.\d*)/);Ae&&(Ae=Number(Ae[1])),Ae&&Ae>=15&&(J=!1,se=!0);var rt=Y&&(re||J&&(Ae==null||Ae<12.11)),Ie=pe||P&&I>=9;function _(e){return new RegExp("(^|\\s)"+e+"(?:$|\\s)\\s*")}var j=function(e,t){var n=e.className,r=_(t).exec(n);if(r){var i=n.slice(r.index+r[0].length);e.className=n.slice(0,r.index)+(i?r[1]+i:"")}};function k(e){for(var t=e.childNodes.length;t>0;--t)e.removeChild(e.firstChild);return e}function z(e,t){return k(e).appendChild(t)}function c(e,t,n,r){var i=document.createElement(e);if(n&&(i.className=n),r&&(i.style.cssText=r),typeof t=="string")i.appendChild(document.createTextNode(t));else if(t)for(var o=0;o<t.length;++o)i.appendChild(t[o]);return i}function D(e,t,n,r){var i=c(e,t,n,r);return i.setAttribute("role","presentation"),i}var L;document.createRange?L=function(e,t,n,r){var i=document.createRange();return i.setEnd(r||e,n),i.setStart(e,t),i}:L=function(e,t,n){var r=document.body.createTextRange();try{r.moveToElementText(e.parentNode)}catch{return r}return r.collapse(!0),r.moveEnd("character",n),r.moveStart("character",t),r};function U(e,t){if(t.nodeType==3&&(t=t.parentNode),e.contains)return e.contains(t);do if(t.nodeType==11&&(t=t.host),t==e)return!0;while(t=t.parentNode)}function ve(){var e;try{e=document.activeElement}catch{e=document.body||null}for(;e&&e.shadowRoot&&e.shadowRoot.activeElement;)e=e.shadowRoot.activeElement;return e}function De(e,t){var n=e.className;_(t).test(n)||(e.className+=(n?" ":"")+t)}function xt(e,t){for(var n=e.split(" "),r=0;r<n.length;r++)n[r]&&!_(n[r]).test(t)&&(t+=" "+n[r]);return t}var Kt=function(e){e.select()};$?Kt=function(e){e.selectionStart=0,e.selectionEnd=e.value.length}:P&&(Kt=function(e){try{e.select()}catch{}});function wt(e){var t=Array.prototype.slice.call(arguments,1);return function(){return e.apply(null,t)}}function vt(e,t,n){t||(t={});for(var r in e)e.hasOwnProperty(r)&&(n!==!1||!t.hasOwnProperty(r))&&(t[r]=e[r]);return t}function be(e,t,n,r,i){t==null&&(t=e.search(/[^\s\u00a0]/),t==-1&&(t=e.length));for(var o=r||0,l=i||0;;){var a=e.indexOf(" ",o);if(a<0||a>=t)return l+(t-o);l+=a-o,l+=n-l%n,o=a+1}}var K=function(){this.id=null,this.f=null,this.time=0,this.handler=wt(this.onTimeout,this)};K.prototype.onTimeout=function(e){e.id=0,e.time<=+new Date?e.f():setTimeout(e.handler,e.time-+new Date)},K.prototype.set=function(e,t){this.f=t;var n=+new Date+e;(!this.id||n<this.time)&&(clearTimeout(this.id),this.id=setTimeout(this.handler,e),this.time=n)};function E(e,t){for(var n=0;n<e.length;++n)if(e[n]==t)return n;return-1}var ne=50,ye={toString:function(){return"CodeMirror.Pass"}},Qe={scroll:!1},H={origin:"*mouse"},ie={origin:"+move"};function _t(e,t,n){for(var r=0,i=0;;){var o=e.indexOf(" ",r);o==-1&&(o=e.length);var l=o-r;if(o==e.length||i+l>=t)return r+Math.min(l,t-i);if(i+=o-r,i+=n-i%n,r=o+1,i>=t)return r}}var Dt=[""];function Ct(e){for(;Dt.length<=e;)Dt.push(ee(Dt)+" ");return Dt[e]}function ee(e){return e[e.length-1]}function ce(e,t){for(var n=[],r=0;r<e.length;r++)n[r]=t(e[r],r);return n}function Ve(e,t,n){for(var r=0,i=n(t);r<e.length&&n(e[r])<=i;)r++;e.splice(r,0,t)}function Ot(){}function gt(e,t){var n;return Object.create?n=Object.create(e):(Ot.prototype=e,n=new Ot),t&&vt(t,n),n}var fr=/[\u00df\u0587\u0590-\u05f4\u0600-\u06ff\u3040-\u309f\u30a0-\u30ff\u3400-\u4db5\u4e00-\u9fcc\uac00-\ud7af]/;function me(e){return/\w/.test(e)||e>"\x80"&&(e.toUpperCase()!=e.toLowerCase()||fr.test(e))}function y(e,t){return t?t.source.indexOf("\\w")>-1&&me(e)?!0:t.test(e):me(e)}function T(e){for(var t in e)if(e.hasOwnProperty(t)&&e[t])return!1;return!0}var x=/[\u0300-\u036f\u0483-\u0489\u0591-\u05bd\u05bf\u05c1\u05c2\u05c4\u05c5\u05c7\u0610-\u061a\u064b-\u065e\u0670\u06d6-\u06dc\u06de-\u06e4\u06e7\u06e8\u06ea-\u06ed\u0711\u0730-\u074a\u07a6-\u07b0\u07eb-\u07f3\u0816-\u0819\u081b-\u0823\u0825-\u0827\u0829-\u082d\u0900-\u0902\u093c\u0941-\u0948\u094d\u0951-\u0955\u0962\u0963\u0981\u09bc\u09be\u09c1-\u09c4\u09cd\u09d7\u09e2\u09e3\u0a01\u0a02\u0a3c\u0a41\u0a42\u0a47\u0a48\u0a4b-\u0a4d\u0a51\u0a70\u0a71\u0a75\u0a81\u0a82\u0abc\u0ac1-\u0ac5\u0ac7\u0ac8\u0acd\u0ae2\u0ae3\u0b01\u0b3c\u0b3e\u0b3f\u0b41-\u0b44\u0b4d\u0b56\u0b57\u0b62\u0b63\u0b82\u0bbe\u0bc0\u0bcd\u0bd7\u0c3e-\u0c40\u0c46-\u0c48\u0c4a-\u0c4d\u0c55\u0c56\u0c62\u0c63\u0cbc\u0cbf\u0cc2\u0cc6\u0ccc\u0ccd\u0cd5\u0cd6\u0ce2\u0ce3\u0d3e\u0d41-\u0d44\u0d4d\u0d57\u0d62\u0d63\u0dca\u0dcf\u0dd2-\u0dd4\u0dd6\u0ddf\u0e31\u0e34-\u0e3a\u0e47-\u0e4e\u0eb1\u0eb4-\u0eb9\u0ebb\u0ebc\u0ec8-\u0ecd\u0f18\u0f19\u0f35\u0f37\u0f39\u0f71-\u0f7e\u0f80-\u0f84\u0f86\u0f87\u0f90-\u0f97\u0f99-\u0fbc\u0fc6\u102d-\u1030\u1032-\u1037\u1039\u103a\u103d\u103e\u1058\u1059\u105e-\u1060\u1071-\u1074\u1082\u1085\u1086\u108d\u109d\u135f\u1712-\u1714\u1732-\u1734\u1752\u1753\u1772\u1773\u17b7-\u17bd\u17c6\u17c9-\u17d3\u17dd\u180b-\u180d\u18a9\u1920-\u1922\u1927\u1928\u1932\u1939-\u193b\u1a17\u1a18\u1a56\u1a58-\u1a5e\u1a60\u1a62\u1a65-\u1a6c\u1a73-\u1a7c\u1a7f\u1b00-\u1b03\u1b34\u1b36-\u1b3a\u1b3c\u1b42\u1b6b-\u1b73\u1b80\u1b81\u1ba2-\u1ba5\u1ba8\u1ba9\u1c2c-\u1c33\u1c36\u1c37\u1cd0-\u1cd2\u1cd4-\u1ce0\u1ce2-\u1ce8\u1ced\u1dc0-\u1de6\u1dfd-\u1dff\u200c\u200d\u20d0-\u20f0\u2cef-\u2cf1\u2de0-\u2dff\u302a-\u302f\u3099\u309a\ua66f-\ua672\ua67c\ua67d\ua6f0\ua6f1\ua802\ua806\ua80b\ua825\ua826\ua8c4\ua8e0-\ua8f1\ua926-\ua92d\ua947-\ua951\ua980-\ua982\ua9b3\ua9b6-\ua9b9\ua9bc\uaa29-\uaa2e\uaa31\uaa32\uaa35\uaa36\uaa43\uaa4c\uaab0\uaab2-\uaab4\uaab7\uaab8\uaabe\uaabf\uaac1\uabe5\uabe8\uabed\udc00-\udfff\ufb1e\ufe00-\ufe0f\ufe20-\ufe26\uff9e\uff9f]/;function oe(e){return e.charCodeAt(0)>=768&&x.test(e)}function Ue(e,t,n){for(;(n<0?t>0:t<e.length)&&oe(e.charAt(t));)t+=n;return t}function cr(e,t,n){for(var r=t>n?-1:1;;){if(t==n)return t;var i=(t+n)/2,o=r<0?Math.ceil(i):Math.floor(i);if(o==t)return e(o)?t:n;e(o)?n=o:t=o+r}}function Ut(e,t,n,r){if(!e)return r(t,n,"ltr",0);for(var i=!1,o=0;o<e.length;++o){var l=e[o];(l.from<n&&l.to>t||t==n&&l.to==t)&&(r(Math.max(l.from,t),Math.min(l.to,n),l.level==1?"rtl":"ltr",o),i=!0)}i||r(t,n,"ltr")}var Se=null;function Lt(e,t,n){var r;Se=null;for(var i=0;i<e.length;++i){var o=e[i];if(o.from<t&&o.to>t)return i;o.to==t&&(o.from!=o.to&&n=="before"?r=i:Se=i),o.from==t&&(o.from!=o.to&&n!="before"?r=i:Se=i)}return r!=null?r:Se}var Sr=function(){var e="bbbbbbbbbtstwsbbbbbbbbbbbbbbssstwNN%%%NNNNNN,N,N1111111111NNNNNNNLLLLLLLLLLLLLLLLLLLLLLLLLLNNNNNNLLLLLLLLLLLLLLLLLLLLLLLLLLNNNNbbbbbbsbbbbbbbbbbbbbbbbbbbbbbbbbb,N%%%%NNNNLNNNNN%%11NLNNN1LNNNNNLLLLLLLLLLLLLLLLLLLLLLLNLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLN",t="nnnnnnNNr%%r,rNNmmmmmmmmmmmrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrmmmmmmmmmmmmmmmmmmmmmnnnnnnnnnn%nnrrrmrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrmmmmmmmnNmmmmmmrrmmNmmmmrr1111111111";function n(u){return u<=247?e.charAt(u):1424<=u&&u<=1524?"R":1536<=u&&u<=1785?t.charAt(u-1536):1774<=u&&u<=2220?"r":8192<=u&&u<=8203?"w":u==8204?"b":"L"}var r=/[\u0590-\u05f4\u0600-\u06ff\u0700-\u08ac]/,i=/[stwN]/,o=/[LRr]/,l=/[Lb1n]/,a=/[1n]/;function s(u,d,h){this.level=u,this.from=d,this.to=h}return function(u,d){var h=d=="ltr"?"L":"R";if(u.length==0||d=="ltr"&&!r.test(u))return!1;for(var m=u.length,g=[],b=0;b<m;++b)g.push(n(u.charCodeAt(b)));for(var S=0,C=h;S<m;++S){var N=g[S];N=="m"?g[S]=C:C=N}for(var O=0,A=h;O<m;++O){var W=g[O];W=="1"&&A=="r"?g[O]="n":o.test(W)&&(A=W,W=="r"&&(g[O]="R"))}for(var q=1,R=g[0];q<m-1;++q){var V=g[q];V=="+"&&R=="1"&&g[q+1]=="1"?g[q]="1":V==","&&R==g[q+1]&&(R=="1"||R=="n")&&(g[q]=R),R=V}for(var ge=0;ge<m;++ge){var Xe=g[ge];if(Xe==",")g[ge]="N";else if(Xe=="%"){var Ce=void 0;for(Ce=ge+1;Ce<m&&g[Ce]=="%";++Ce);for(var pt=ge&&g[ge-1]=="!"||Ce<m&&g[Ce]=="1"?"1":"N",ut=ge;ut<Ce;++ut)g[ut]=pt;ge=Ce-1}}for(var Ee=0,ft=h;Ee<m;++Ee){var Ze=g[Ee];ft=="L"&&Ze=="1"?g[Ee]="L":o.test(Ze)&&(ft=Ze)}for(var Ke=0;Ke<m;++Ke)if(i.test(g[Ke])){var Fe=void 0;for(Fe=Ke+1;Fe<m&&i.test(g[Fe]);++Fe);for(var Ne=(Ke?g[Ke-1]:h)=="L",ct=(Fe<m?g[Fe]:h)=="L",Yr=Ne==ct?Ne?"L":"R":h,ur=Ke;ur<Fe;++ur)g[ur]=Yr;Ke=Fe-1}for(var tt=[],Rt,Ye=0;Ye<m;)if(l.test(g[Ye])){var io=Ye;for(++Ye;Ye<m&&l.test(g[Ye]);++Ye);tt.push(new s(0,io,Ye))}else{var Vt=Ye,wr=tt.length,kr=d=="rtl"?1:0;for(++Ye;Ye<m&&g[Ye]!="L";++Ye);for(var ot=Vt;ot<Ye;)if(a.test(g[ot])){Vt<ot&&(tt.splice(wr,0,new s(1,Vt,ot)),wr+=kr);var jr=ot;for(++ot;ot<Ye&&a.test(g[ot]);++ot);tt.splice(wr,0,new s(2,jr,ot)),wr+=kr,Vt=ot}else++ot;Vt<Ye&&tt.splice(wr,0,new s(1,Vt,Ye))}return d=="ltr"&&(tt[0].level==1&&(Rt=u.match(/^\s+/))&&(tt[0].from=Rt[0].length,tt.unshift(new s(0,0,Rt[0].length))),ee(tt).level==1&&(Rt=u.match(/\s+$/))&&(ee(tt).to-=Rt[0].length,tt.push(new s(0,m-Rt[0].length,m)))),d=="rtl"?tt.reverse():tt}}();function nt(e,t){var n=e.order;return n==null&&(n=e.order=Sr(e.text,t)),n}var On=[],G=function(e,t,n){if(e.addEventListener)e.addEventListener(t,n,!1);else if(e.attachEvent)e.attachEvent("on"+t,n);else{var r=e._handlers||(e._handlers={});r[t]=(r[t]||On).concat(n)}};function Jr(e,t){return e._handlers&&e._handlers[t]||On}function te(e,t,n){if(e.removeEventListener)e.removeEventListener(t,n,!1);else if(e.detachEvent)e.detachEvent("on"+t,n);else{var r=e._handlers,i=r&&r[t];if(i){var o=E(i,n);o>-1&&(r[t]=i.slice(0,o).concat(i.slice(o+1)))}}}function Me(e,t){var n=Jr(e,t);if(!!n.length)for(var r=Array.prototype.slice.call(arguments,2),i=0;i<n.length;++i)n[i].apply(null,r)}function xe(e,t,n){return typeof t=="string"&&(t={type:t,preventDefault:function(){this.defaultPrevented=!0}}),Me(e,n||t.type,e,t),dr(t)||t.codemirrorIgnore}function Cr(e){var t=e._handlers&&e._handlers.cursorActivity;if(!!t)for(var n=e.curOp.cursorActivityHandlers||(e.curOp.cursorActivityHandlers=[]),r=0;r<t.length;++r)E(n,t[r])==-1&&n.push(t[r])}function He(e,t){return Jr(e,t).length>0}function $t(e){e.prototype.on=function(t,n){G(this,t,n)},e.prototype.off=function(t,n){te(this,t,n)}}function Be(e){e.preventDefault?e.preventDefault():e.returnValue=!1}function Wn(e){e.stopPropagation?e.stopPropagation():e.cancelBubble=!0}function dr(e){return e.defaultPrevented!=null?e.defaultPrevented:e.returnValue==!1}function $e(e){Be(e),Wn(e)}function Lr(e){return e.target||e.srcElement}function Pn(e){var t=e.which;return t==null&&(e.button&1?t=1:e.button&2?t=3:e.button&4&&(t=2)),Y&&e.ctrlKey&&t==1&&(t=3),t}var Wt=function(){if(P&&I<9)return!1;var e=c("div");return"draggable"in e||"dragDrop"in e}(),Qr;function zn(e){if(Qr==null){var t=c("span","\u200B");z(e,c("span",[t,document.createTextNode("x")])),e.firstChild.offsetHeight!=0&&(Qr=t.offsetWidth<=1&&t.offsetHeight>2&&!(P&&I<8))}var n=Qr?c("span","\u200B"):c("span","\xA0",null,"display: inline-block; width: 1px; margin-right: -1px");return n.setAttribute("cm-text",""),n}var Tr;function di(e){if(Tr!=null)return Tr;var t=z(e,document.createTextNode("A\u062EA")),n=L(t,0,1).getBoundingClientRect(),r=L(t,1,2).getBoundingClientRect();return k(e),!n||n.left==n.right?!1:Tr=r.right-n.right<3}var Pt=` +import{H as pu}from"./pages/main.71d0edc5.js";var lo={exports:{}},sa;function An(){return sa||(sa=1,function(Zr,Dn){(function(F,We){Zr.exports=We()})(pu,function(){var F=navigator.userAgent,We=navigator.platform,pe=/gecko\/\d/i.test(F),Je=/MSIE \d/.test(F),dt=/Trident\/(?:[7-9]|\d{2,})\..*rv:(\d+)/.exec(F),Pe=/Edge\/(\d+)/.exec(F),P=Je||dt||Pe,I=P&&(Je?document.documentMode||6:+(Pe||dt)[1]),se=!Pe&&/WebKit\//.test(F),re=se&&/Qt\/\d+\.\d+/.test(F),X=!Pe&&/Chrome\//.test(F),J=/Opera\//.test(F),fe=/Apple Computer/.test(navigator.vendor),Le=/Mac OS X 1\d\D([8-9]|\d\d)\D/.test(F),ze=/PhantomJS/.test(F),$=!Pe&&/AppleWebKit/.test(F)&&/Mobile\/\w+/.test(F),_e=/Android/.test(F),Q=$||_e||/webOS|BlackBerry|Opera Mini|Opera Mobi|IEMobile/i.test(F),Y=$||/Mac/.test(We),Te=/\bCrOS\b/.test(F),bt=/win/i.test(We),Ae=J&&F.match(/Version\/(\d*\.\d*)/);Ae&&(Ae=Number(Ae[1])),Ae&&Ae>=15&&(J=!1,se=!0);var rt=Y&&(re||J&&(Ae==null||Ae<12.11)),Ie=pe||P&&I>=9;function _(e){return new RegExp("(^|\\s)"+e+"(?:$|\\s)\\s*")}var j=function(e,t){var n=e.className,r=_(t).exec(n);if(r){var i=n.slice(r.index+r[0].length);e.className=n.slice(0,r.index)+(i?r[1]+i:"")}};function k(e){for(var t=e.childNodes.length;t>0;--t)e.removeChild(e.firstChild);return e}function z(e,t){return k(e).appendChild(t)}function c(e,t,n,r){var i=document.createElement(e);if(n&&(i.className=n),r&&(i.style.cssText=r),typeof t=="string")i.appendChild(document.createTextNode(t));else if(t)for(var o=0;o<t.length;++o)i.appendChild(t[o]);return i}function D(e,t,n,r){var i=c(e,t,n,r);return i.setAttribute("role","presentation"),i}var L;document.createRange?L=function(e,t,n,r){var i=document.createRange();return i.setEnd(r||e,n),i.setStart(e,t),i}:L=function(e,t,n){var r=document.body.createTextRange();try{r.moveToElementText(e.parentNode)}catch{return r}return r.collapse(!0),r.moveEnd("character",n),r.moveStart("character",t),r};function U(e,t){if(t.nodeType==3&&(t=t.parentNode),e.contains)return e.contains(t);do if(t.nodeType==11&&(t=t.host),t==e)return!0;while(t=t.parentNode)}function ve(){var e;try{e=document.activeElement}catch{e=document.body||null}for(;e&&e.shadowRoot&&e.shadowRoot.activeElement;)e=e.shadowRoot.activeElement;return e}function De(e,t){var n=e.className;_(t).test(n)||(e.className+=(n?" ":"")+t)}function xt(e,t){for(var n=e.split(" "),r=0;r<n.length;r++)n[r]&&!_(n[r]).test(t)&&(t+=" "+n[r]);return t}var Kt=function(e){e.select()};$?Kt=function(e){e.selectionStart=0,e.selectionEnd=e.value.length}:P&&(Kt=function(e){try{e.select()}catch{}});function wt(e){var t=Array.prototype.slice.call(arguments,1);return function(){return e.apply(null,t)}}function vt(e,t,n){t||(t={});for(var r in e)e.hasOwnProperty(r)&&(n!==!1||!t.hasOwnProperty(r))&&(t[r]=e[r]);return t}function be(e,t,n,r,i){t==null&&(t=e.search(/[^\s\u00a0]/),t==-1&&(t=e.length));for(var o=r||0,l=i||0;;){var a=e.indexOf(" ",o);if(a<0||a>=t)return l+(t-o);l+=a-o,l+=n-l%n,o=a+1}}var K=function(){this.id=null,this.f=null,this.time=0,this.handler=wt(this.onTimeout,this)};K.prototype.onTimeout=function(e){e.id=0,e.time<=+new Date?e.f():setTimeout(e.handler,e.time-+new Date)},K.prototype.set=function(e,t){this.f=t;var n=+new Date+e;(!this.id||n<this.time)&&(clearTimeout(this.id),this.id=setTimeout(this.handler,e),this.time=n)};function E(e,t){for(var n=0;n<e.length;++n)if(e[n]==t)return n;return-1}var ne=50,ye={toString:function(){return"CodeMirror.Pass"}},Qe={scroll:!1},H={origin:"*mouse"},ie={origin:"+move"};function _t(e,t,n){for(var r=0,i=0;;){var o=e.indexOf(" ",r);o==-1&&(o=e.length);var l=o-r;if(o==e.length||i+l>=t)return r+Math.min(l,t-i);if(i+=o-r,i+=n-i%n,r=o+1,i>=t)return r}}var Dt=[""];function Ct(e){for(;Dt.length<=e;)Dt.push(ee(Dt)+" ");return Dt[e]}function ee(e){return e[e.length-1]}function ce(e,t){for(var n=[],r=0;r<e.length;r++)n[r]=t(e[r],r);return n}function Ve(e,t,n){for(var r=0,i=n(t);r<e.length&&n(e[r])<=i;)r++;e.splice(r,0,t)}function Ot(){}function gt(e,t){var n;return Object.create?n=Object.create(e):(Ot.prototype=e,n=new Ot),t&&vt(t,n),n}var fr=/[\u00df\u0587\u0590-\u05f4\u0600-\u06ff\u3040-\u309f\u30a0-\u30ff\u3400-\u4db5\u4e00-\u9fcc\uac00-\ud7af]/;function me(e){return/\w/.test(e)||e>"\x80"&&(e.toUpperCase()!=e.toLowerCase()||fr.test(e))}function y(e,t){return t?t.source.indexOf("\\w")>-1&&me(e)?!0:t.test(e):me(e)}function T(e){for(var t in e)if(e.hasOwnProperty(t)&&e[t])return!1;return!0}var x=/[\u0300-\u036f\u0483-\u0489\u0591-\u05bd\u05bf\u05c1\u05c2\u05c4\u05c5\u05c7\u0610-\u061a\u064b-\u065e\u0670\u06d6-\u06dc\u06de-\u06e4\u06e7\u06e8\u06ea-\u06ed\u0711\u0730-\u074a\u07a6-\u07b0\u07eb-\u07f3\u0816-\u0819\u081b-\u0823\u0825-\u0827\u0829-\u082d\u0900-\u0902\u093c\u0941-\u0948\u094d\u0951-\u0955\u0962\u0963\u0981\u09bc\u09be\u09c1-\u09c4\u09cd\u09d7\u09e2\u09e3\u0a01\u0a02\u0a3c\u0a41\u0a42\u0a47\u0a48\u0a4b-\u0a4d\u0a51\u0a70\u0a71\u0a75\u0a81\u0a82\u0abc\u0ac1-\u0ac5\u0ac7\u0ac8\u0acd\u0ae2\u0ae3\u0b01\u0b3c\u0b3e\u0b3f\u0b41-\u0b44\u0b4d\u0b56\u0b57\u0b62\u0b63\u0b82\u0bbe\u0bc0\u0bcd\u0bd7\u0c3e-\u0c40\u0c46-\u0c48\u0c4a-\u0c4d\u0c55\u0c56\u0c62\u0c63\u0cbc\u0cbf\u0cc2\u0cc6\u0ccc\u0ccd\u0cd5\u0cd6\u0ce2\u0ce3\u0d3e\u0d41-\u0d44\u0d4d\u0d57\u0d62\u0d63\u0dca\u0dcf\u0dd2-\u0dd4\u0dd6\u0ddf\u0e31\u0e34-\u0e3a\u0e47-\u0e4e\u0eb1\u0eb4-\u0eb9\u0ebb\u0ebc\u0ec8-\u0ecd\u0f18\u0f19\u0f35\u0f37\u0f39\u0f71-\u0f7e\u0f80-\u0f84\u0f86\u0f87\u0f90-\u0f97\u0f99-\u0fbc\u0fc6\u102d-\u1030\u1032-\u1037\u1039\u103a\u103d\u103e\u1058\u1059\u105e-\u1060\u1071-\u1074\u1082\u1085\u1086\u108d\u109d\u135f\u1712-\u1714\u1732-\u1734\u1752\u1753\u1772\u1773\u17b7-\u17bd\u17c6\u17c9-\u17d3\u17dd\u180b-\u180d\u18a9\u1920-\u1922\u1927\u1928\u1932\u1939-\u193b\u1a17\u1a18\u1a56\u1a58-\u1a5e\u1a60\u1a62\u1a65-\u1a6c\u1a73-\u1a7c\u1a7f\u1b00-\u1b03\u1b34\u1b36-\u1b3a\u1b3c\u1b42\u1b6b-\u1b73\u1b80\u1b81\u1ba2-\u1ba5\u1ba8\u1ba9\u1c2c-\u1c33\u1c36\u1c37\u1cd0-\u1cd2\u1cd4-\u1ce0\u1ce2-\u1ce8\u1ced\u1dc0-\u1de6\u1dfd-\u1dff\u200c\u200d\u20d0-\u20f0\u2cef-\u2cf1\u2de0-\u2dff\u302a-\u302f\u3099\u309a\ua66f-\ua672\ua67c\ua67d\ua6f0\ua6f1\ua802\ua806\ua80b\ua825\ua826\ua8c4\ua8e0-\ua8f1\ua926-\ua92d\ua947-\ua951\ua980-\ua982\ua9b3\ua9b6-\ua9b9\ua9bc\uaa29-\uaa2e\uaa31\uaa32\uaa35\uaa36\uaa43\uaa4c\uaab0\uaab2-\uaab4\uaab7\uaab8\uaabe\uaabf\uaac1\uabe5\uabe8\uabed\udc00-\udfff\ufb1e\ufe00-\ufe0f\ufe20-\ufe26\uff9e\uff9f]/;function oe(e){return e.charCodeAt(0)>=768&&x.test(e)}function Ue(e,t,n){for(;(n<0?t>0:t<e.length)&&oe(e.charAt(t));)t+=n;return t}function cr(e,t,n){for(var r=t>n?-1:1;;){if(t==n)return t;var i=(t+n)/2,o=r<0?Math.ceil(i):Math.floor(i);if(o==t)return e(o)?t:n;e(o)?n=o:t=o+r}}function Ut(e,t,n,r){if(!e)return r(t,n,"ltr",0);for(var i=!1,o=0;o<e.length;++o){var l=e[o];(l.from<n&&l.to>t||t==n&&l.to==t)&&(r(Math.max(l.from,t),Math.min(l.to,n),l.level==1?"rtl":"ltr",o),i=!0)}i||r(t,n,"ltr")}var Se=null;function Lt(e,t,n){var r;Se=null;for(var i=0;i<e.length;++i){var o=e[i];if(o.from<t&&o.to>t)return i;o.to==t&&(o.from!=o.to&&n=="before"?r=i:Se=i),o.from==t&&(o.from!=o.to&&n!="before"?r=i:Se=i)}return r!=null?r:Se}var Sr=function(){var e="bbbbbbbbbtstwsbbbbbbbbbbbbbbssstwNN%%%NNNNNN,N,N1111111111NNNNNNNLLLLLLLLLLLLLLLLLLLLLLLLLLNNNNNNLLLLLLLLLLLLLLLLLLLLLLLLLLNNNNbbbbbbsbbbbbbbbbbbbbbbbbbbbbbbbbb,N%%%%NNNNLNNNNN%%11NLNNN1LNNNNNLLLLLLLLLLLLLLLLLLLLLLLNLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLN",t="nnnnnnNNr%%r,rNNmmmmmmmmmmmrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrmmmmmmmmmmmmmmmmmmmmmnnnnnnnnnn%nnrrrmrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrmmmmmmmnNmmmmmmrrmmNmmmmrr1111111111";function n(u){return u<=247?e.charAt(u):1424<=u&&u<=1524?"R":1536<=u&&u<=1785?t.charAt(u-1536):1774<=u&&u<=2220?"r":8192<=u&&u<=8203?"w":u==8204?"b":"L"}var r=/[\u0590-\u05f4\u0600-\u06ff\u0700-\u08ac]/,i=/[stwN]/,o=/[LRr]/,l=/[Lb1n]/,a=/[1n]/;function s(u,d,h){this.level=u,this.from=d,this.to=h}return function(u,d){var h=d=="ltr"?"L":"R";if(u.length==0||d=="ltr"&&!r.test(u))return!1;for(var m=u.length,g=[],b=0;b<m;++b)g.push(n(u.charCodeAt(b)));for(var S=0,C=h;S<m;++S){var N=g[S];N=="m"?g[S]=C:C=N}for(var O=0,A=h;O<m;++O){var W=g[O];W=="1"&&A=="r"?g[O]="n":o.test(W)&&(A=W,W=="r"&&(g[O]="R"))}for(var q=1,R=g[0];q<m-1;++q){var V=g[q];V=="+"&&R=="1"&&g[q+1]=="1"?g[q]="1":V==","&&R==g[q+1]&&(R=="1"||R=="n")&&(g[q]=R),R=V}for(var ge=0;ge<m;++ge){var Xe=g[ge];if(Xe==",")g[ge]="N";else if(Xe=="%"){var Ce=void 0;for(Ce=ge+1;Ce<m&&g[Ce]=="%";++Ce);for(var pt=ge&&g[ge-1]=="!"||Ce<m&&g[Ce]=="1"?"1":"N",ut=ge;ut<Ce;++ut)g[ut]=pt;ge=Ce-1}}for(var Ee=0,ft=h;Ee<m;++Ee){var Ze=g[Ee];ft=="L"&&Ze=="1"?g[Ee]="L":o.test(Ze)&&(ft=Ze)}for(var Ke=0;Ke<m;++Ke)if(i.test(g[Ke])){var Fe=void 0;for(Fe=Ke+1;Fe<m&&i.test(g[Fe]);++Fe);for(var Ne=(Ke?g[Ke-1]:h)=="L",ct=(Fe<m?g[Fe]:h)=="L",Yr=Ne==ct?Ne?"L":"R":h,ur=Ke;ur<Fe;++ur)g[ur]=Yr;Ke=Fe-1}for(var tt=[],Rt,Ye=0;Ye<m;)if(l.test(g[Ye])){var io=Ye;for(++Ye;Ye<m&&l.test(g[Ye]);++Ye);tt.push(new s(0,io,Ye))}else{var Vt=Ye,wr=tt.length,kr=d=="rtl"?1:0;for(++Ye;Ye<m&&g[Ye]!="L";++Ye);for(var ot=Vt;ot<Ye;)if(a.test(g[ot])){Vt<ot&&(tt.splice(wr,0,new s(1,Vt,ot)),wr+=kr);var jr=ot;for(++ot;ot<Ye&&a.test(g[ot]);++ot);tt.splice(wr,0,new s(2,jr,ot)),wr+=kr,Vt=ot}else++ot;Vt<Ye&&tt.splice(wr,0,new s(1,Vt,Ye))}return d=="ltr"&&(tt[0].level==1&&(Rt=u.match(/^\s+/))&&(tt[0].from=Rt[0].length,tt.unshift(new s(0,0,Rt[0].length))),ee(tt).level==1&&(Rt=u.match(/\s+$/))&&(ee(tt).to-=Rt[0].length,tt.push(new s(0,m-Rt[0].length,m)))),d=="rtl"?tt.reverse():tt}}();function nt(e,t){var n=e.order;return n==null&&(n=e.order=Sr(e.text,t)),n}var On=[],G=function(e,t,n){if(e.addEventListener)e.addEventListener(t,n,!1);else if(e.attachEvent)e.attachEvent("on"+t,n);else{var r=e._handlers||(e._handlers={});r[t]=(r[t]||On).concat(n)}};function Jr(e,t){return e._handlers&&e._handlers[t]||On}function te(e,t,n){if(e.removeEventListener)e.removeEventListener(t,n,!1);else if(e.detachEvent)e.detachEvent("on"+t,n);else{var r=e._handlers,i=r&&r[t];if(i){var o=E(i,n);o>-1&&(r[t]=i.slice(0,o).concat(i.slice(o+1)))}}}function Me(e,t){var n=Jr(e,t);if(!!n.length)for(var r=Array.prototype.slice.call(arguments,2),i=0;i<n.length;++i)n[i].apply(null,r)}function xe(e,t,n){return typeof t=="string"&&(t={type:t,preventDefault:function(){this.defaultPrevented=!0}}),Me(e,n||t.type,e,t),dr(t)||t.codemirrorIgnore}function Cr(e){var t=e._handlers&&e._handlers.cursorActivity;if(!!t)for(var n=e.curOp.cursorActivityHandlers||(e.curOp.cursorActivityHandlers=[]),r=0;r<t.length;++r)E(n,t[r])==-1&&n.push(t[r])}function He(e,t){return Jr(e,t).length>0}function $t(e){e.prototype.on=function(t,n){G(this,t,n)},e.prototype.off=function(t,n){te(this,t,n)}}function Be(e){e.preventDefault?e.preventDefault():e.returnValue=!1}function Wn(e){e.stopPropagation?e.stopPropagation():e.cancelBubble=!0}function dr(e){return e.defaultPrevented!=null?e.defaultPrevented:e.returnValue==!1}function $e(e){Be(e),Wn(e)}function Lr(e){return e.target||e.srcElement}function Pn(e){var t=e.which;return t==null&&(e.button&1?t=1:e.button&2?t=3:e.button&4&&(t=2)),Y&&e.ctrlKey&&t==1&&(t=3),t}var Wt=function(){if(P&&I<9)return!1;var e=c("div");return"draggable"in e||"dragDrop"in e}(),Qr;function zn(e){if(Qr==null){var t=c("span","\u200B");z(e,c("span",[t,document.createTextNode("x")])),e.firstChild.offsetHeight!=0&&(Qr=t.offsetWidth<=1&&t.offsetHeight>2&&!(P&&I<8))}var n=Qr?c("span","\u200B"):c("span","\xA0",null,"display: inline-block; width: 1px; margin-right: -1px");return n.setAttribute("cm-text",""),n}var Tr;function di(e){if(Tr!=null)return Tr;var t=z(e,document.createTextNode("A\u062EA")),n=L(t,0,1).getBoundingClientRect(),r=L(t,1,2).getBoundingClientRect();return k(e),!n||n.left==n.right?!1:Tr=r.right-n.right<3}var Pt=` b`.split(/\n/).length!=3?function(e){for(var t=0,n=[],r=e.length;t<=r;){var i=e.indexOf(` `,t);i==-1&&(i=e.length);var o=e.slice(t,e.charAt(i-1)=="\r"?i-1:i),l=o.indexOf("\r");l!=-1?(n.push(o.slice(0,l)),t+=l+1):(n.push(o),t=i+1)}return n}:function(e){return e.split(/\r\n?|\n/)},zt=window.getSelection?function(e){try{return e.selectionStart!=e.selectionEnd}catch{return!1}}:function(e){var t;try{t=e.ownerDocument.selection.createRange()}catch{}return!t||t.parentElement()!=e?!1:t.compareEndPoints("StartToEnd",t)!=0},er=function(){var e=c("div");return"oncopy"in e?!0:(e.setAttribute("oncopy","return;"),typeof e.oncopy=="function")}(),Mr=null;function Gt(e){if(Mr!=null)return Mr;var t=z(e,c("span","x")),n=t.getBoundingClientRect(),r=L(t,0,1).getBoundingClientRect();return Mr=Math.abs(n.left-r.left)>1}var Vr={},qt={};function Nr(e,t){arguments.length>2&&(t.dependencies=Array.prototype.slice.call(arguments,2)),Vr[e]=t}function Tt(e,t){qt[e]=t}function Xt(e){if(typeof e=="string"&&qt.hasOwnProperty(e))e=qt[e];else if(e&&typeof e.name=="string"&&qt.hasOwnProperty(e.name)){var t=qt[e.name];typeof t=="string"&&(t={name:t}),e=gt(t,e),e.name=t.name}else{if(typeof e=="string"&&/^[\w\-]+\/[\w\-]+\+xml$/.test(e))return Xt("application/xml");if(typeof e=="string"&&/^[\w\-]+\/[\w\-]+\+json$/.test(e))return Xt("application/json")}return typeof e=="string"?{name:e}:e||{name:"null"}}function $r(e,t){t=Xt(t);var n=Vr[t.name];if(!n)return $r(e,"text/plain");var r=n(e,t);if(Yt.hasOwnProperty(t.name)){var i=Yt[t.name];for(var o in i)!i.hasOwnProperty(o)||(r.hasOwnProperty(o)&&(r["_"+o]=r[o]),r[o]=i[o])}if(r.name=t.name,t.helperType&&(r.helperType=t.helperType),t.modeProps)for(var l in t.modeProps)r[l]=t.modeProps[l];return r}var Yt={};function hi(e,t){var n=Yt.hasOwnProperty(e)?Yt[e]:Yt[e]={};vt(t,n)}function kt(e,t){if(t===!0)return t;if(e.copyState)return e.copyState(t);var n={};for(var r in t){var i=t[r];i instanceof Array&&(i=i.concat([])),n[r]=i}return n}function Ar(e,t){for(var n;e.innerMode&&(n=e.innerMode(t),!(!n||n.mode==e));)t=n.state,e=n.mode;return n||{mode:e,state:t}}function Hn(e,t,n){return e.startState?e.startState(t,n):!0}var we=function(e,t,n){this.pos=this.start=0,this.string=e,this.tabSize=t||8,this.lastColumnPos=this.lastColumnValue=0,this.lineStart=0,this.lineOracle=n};we.prototype.eol=function(){return this.pos>=this.string.length},we.prototype.sol=function(){return this.pos==this.lineStart},we.prototype.peek=function(){return this.string.charAt(this.pos)||void 0},we.prototype.next=function(){if(this.pos<this.string.length)return this.string.charAt(this.pos++)},we.prototype.eat=function(e){var t=this.string.charAt(this.pos),n;if(typeof e=="string"?n=t==e:n=t&&(e.test?e.test(t):e(t)),n)return++this.pos,t},we.prototype.eatWhile=function(e){for(var t=this.pos;this.eat(e););return this.pos>t},we.prototype.eatSpace=function(){for(var e=this.pos;/[\s\u00a0]/.test(this.string.charAt(this.pos));)++this.pos;return this.pos>e},we.prototype.skipToEnd=function(){this.pos=this.string.length},we.prototype.skipTo=function(e){var t=this.string.indexOf(e,this.pos);if(t>-1)return this.pos=t,!0},we.prototype.backUp=function(e){this.pos-=e},we.prototype.column=function(){return this.lastColumnPos<this.start&&(this.lastColumnValue=be(this.string,this.start,this.tabSize,this.lastColumnPos,this.lastColumnValue),this.lastColumnPos=this.start),this.lastColumnValue-(this.lineStart?be(this.string,this.lineStart,this.tabSize):0)},we.prototype.indentation=function(){return be(this.string,null,this.tabSize)-(this.lineStart?be(this.string,this.lineStart,this.tabSize):0)},we.prototype.match=function(e,t,n){if(typeof e=="string"){var r=function(l){return n?l.toLowerCase():l},i=this.string.substr(this.pos,e.length);if(r(i)==r(e))return t!==!1&&(this.pos+=e.length),!0}else{var o=this.string.slice(this.pos).match(e);return o&&o.index>0?null:(o&&t!==!1&&(this.pos+=o[0].length),o)}},we.prototype.current=function(){return this.string.slice(this.start,this.pos)},we.prototype.hideFirstChars=function(e,t){this.lineStart+=e;try{return t()}finally{this.lineStart-=e}},we.prototype.lookAhead=function(e){var t=this.lineOracle;return t&&t.lookAhead(e)},we.prototype.baseToken=function(){var e=this.lineOracle;return e&&e.baseToken(this.pos)};function B(e,t){if(t-=e.first,t<0||t>=e.size)throw new Error("There is no line "+(t+e.first)+" in the document.");for(var n=e;!n.lines;)for(var r=0;;++r){var i=n.children[r],o=i.chunkSize();if(t<o){n=i;break}t-=o}return n.lines[t]}function Ht(e,t,n){var r=[],i=t.line;return e.iter(t.line,n.line+1,function(o){var l=o.text;i==n.line&&(l=l.slice(0,n.ch)),i==t.line&&(l=l.slice(t.ch)),r.push(l),++i}),r}function en(e,t,n){var r=[];return e.iter(t,n,function(i){r.push(i.text)}),r}function St(e,t){var n=t-e.height;if(n)for(var r=e;r;r=r.parent)r.height+=n}function ae(e){if(e.parent==null)return null;for(var t=e.parent,n=E(t.lines,e),r=t.parent;r;t=r,r=r.parent)for(var i=0;r.children[i]!=t;++i)n+=r.children[i].chunkSize();return n+t.first}function f(e,t){var n=e.first;e:do{for(var r=0;r<e.children.length;++r){var i=e.children[r],o=i.height;if(t<o){e=i;continue e}t-=o,n+=i.chunkSize()}return n}while(!e.lines);for(var l=0;l<e.lines.length;++l){var a=e.lines[l],s=a.height;if(t<s)break;t-=s}return n+l}function p(e,t){return t>=e.first&&t<e.first+e.size}function w(e,t){return String(e.lineNumberFormatter(t+e.firstLineNumber))}function v(e,t,n){if(n===void 0&&(n=null),!(this instanceof v))return new v(e,t,n);this.line=e,this.ch=t,this.sticky=n}function M(e,t){return e.line-t.line||e.ch-t.ch}function le(e,t){return e.sticky==t.sticky&&M(e,t)==0}function de(e){return v(e.line,e.ch)}function Re(e,t){return M(e,t)<0?t:e}function lt(e,t){return M(e,t)<0?e:t}function En(e,t){return Math.max(e.first,Math.min(t,e.first+e.size-1))}function Z(e,t){if(t.line<e.first)return v(e.first,0);var n=e.first+e.size-1;return t.line>n?v(n,B(e,n).text.length):va(t,B(e,t.line).text.length)}function va(e,t){var n=e.ch;return n==null||n>t?v(e.line,t):n<0?v(e.line,0):e}function ao(e,t){for(var n=[],r=0;r<t.length;r++)n[r]=Z(e,t[r]);return n}var Fn=function(e,t){this.state=e,this.lookAhead=t},Et=function(e,t,n,r){this.state=t,this.doc=e,this.line=n,this.maxLookAhead=r||0,this.baseTokens=null,this.baseTokenPos=1};Et.prototype.lookAhead=function(e){var t=this.doc.getLine(this.line+e);return t!=null&&e>this.maxLookAhead&&(this.maxLookAhead=e),t},Et.prototype.baseToken=function(e){if(!this.baseTokens)return null;for(;this.baseTokens[this.baseTokenPos]<=e;)this.baseTokenPos+=2;var t=this.baseTokens[this.baseTokenPos+1];return{type:t&&t.replace(/( |^)overlay .*/,""),size:this.baseTokens[this.baseTokenPos]-e}},Et.prototype.nextLine=function(){this.line++,this.maxLookAhead>0&&this.maxLookAhead--},Et.fromSaved=function(e,t,n){return t instanceof Fn?new Et(e,kt(e.mode,t.state),n,t.lookAhead):new Et(e,kt(e.mode,t),n)},Et.prototype.save=function(e){var t=e!==!1?kt(this.doc.mode,this.state):this.state;return this.maxLookAhead>0?new Fn(t,this.maxLookAhead):t};function so(e,t,n,r){var i=[e.state.modeGen],o={};vo(e,t.text,e.doc.mode,n,function(u,d){return i.push(u,d)},o,r);for(var l=n.state,a=function(u){n.baseTokens=i;var d=e.state.overlays[u],h=1,m=0;n.state=!0,vo(e,t.text,d.mode,n,function(g,b){for(var S=h;m<g;){var C=i[h];C>g&&i.splice(h,1,g,i[h+1],C),h+=2,m=Math.min(g,C)}if(!!b)if(d.opaque)i.splice(S,h-S,g,"overlay "+b),h=S+2;else for(;S<h;S+=2){var N=i[S+1];i[S+1]=(N?N+" ":"")+"overlay "+b}},o),n.state=l,n.baseTokens=null,n.baseTokenPos=1},s=0;s<e.state.overlays.length;++s)a(s);return{styles:i,classes:o.bgClass||o.textClass?o:null}}function uo(e,t,n){if(!t.styles||t.styles[0]!=e.state.modeGen){var r=tn(e,ae(t)),i=t.text.length>e.options.maxHighlightLength&&kt(e.doc.mode,r.state),o=so(e,t,r);i&&(r.state=i),t.stateAfter=r.save(!i),t.styles=o.styles,o.classes?t.styleClasses=o.classes:t.styleClasses&&(t.styleClasses=null),n===e.doc.highlightFrontier&&(e.doc.modeFrontier=Math.max(e.doc.modeFrontier,++e.doc.highlightFrontier))}return t.styles}function tn(e,t,n){var r=e.doc,i=e.display;if(!r.mode.startState)return new Et(r,!0,t);var o=ga(e,t,n),l=o>r.first&&B(r,o-1).stateAfter,a=l?Et.fromSaved(r,l,o):new Et(r,Hn(r.mode),o);return r.iter(o,t,function(s){pi(e,s.text,a);var u=a.line;s.stateAfter=u==t-1||u%5==0||u>=i.viewFrom&&u<i.viewTo?a.save():null,a.nextLine()}),n&&(r.modeFrontier=a.line),a}function pi(e,t,n,r){var i=e.doc.mode,o=new we(t,e.options.tabSize,n);for(o.start=o.pos=r||0,t==""&&fo(i,n.state);!o.eol();)vi(i,o,n.state),o.start=o.pos}function fo(e,t){if(e.blankLine)return e.blankLine(t);if(!!e.innerMode){var n=Ar(e,t);if(n.mode.blankLine)return n.mode.blankLine(n.state)}}function vi(e,t,n,r){for(var i=0;i<10;i++){r&&(r[0]=Ar(e,n).mode);var o=e.token(t,n);if(t.pos>t.start)return o}throw new Error("Mode "+e.name+" failed to advance stream.")}var co=function(e,t,n){this.start=e.start,this.end=e.pos,this.string=e.current(),this.type=t||null,this.state=n};function ho(e,t,n,r){var i=e.doc,o=i.mode,l;t=Z(i,t);var a=B(i,t.line),s=tn(e,t.line,n),u=new we(a.text,e.options.tabSize,s),d;for(r&&(d=[]);(r||u.pos<t.ch)&&!u.eol();)u.start=u.pos,l=vi(o,u,s.state),r&&d.push(new co(u,l,kt(i.mode,s.state)));return r?d:new co(u,l,s.state)}function po(e,t){if(e)for(;;){var n=e.match(/(?:^|\s+)line-(background-)?(\S+)/);if(!n)break;e=e.slice(0,n.index)+e.slice(n.index+n[0].length);var r=n[1]?"bgClass":"textClass";t[r]==null?t[r]=n[2]:new RegExp("(?:^|\\s)"+n[2]+"(?:$|\\s)").test(t[r])||(t[r]+=" "+n[2])}return e}function vo(e,t,n,r,i,o,l){var a=n.flattenSpans;a==null&&(a=e.options.flattenSpans);var s=0,u=null,d=new we(t,e.options.tabSize,r),h,m=e.options.addModeClass&&[null];for(t==""&&po(fo(n,r.state),o);!d.eol();){if(d.pos>e.options.maxHighlightLength?(a=!1,l&&pi(e,t,r,d.pos),d.pos=t.length,h=null):h=po(vi(n,d,r.state,m),o),m){var g=m[0].name;g&&(h="m-"+(h?g+" "+h:g))}if(!a||u!=h){for(;s<d.start;)s=Math.min(d.start,s+5e3),i(s,u);u=h}d.start=d.pos}for(;s<d.pos;){var b=Math.min(d.pos,s+5e3);i(b,u),s=b}}function ga(e,t,n){for(var r,i,o=e.doc,l=n?-1:t-(e.doc.mode.innerMode?1e3:100),a=t;a>l;--a){if(a<=o.first)return o.first;var s=B(o,a-1),u=s.stateAfter;if(u&&(!n||a+(u instanceof Fn?u.lookAhead:0)<=o.modeFrontier))return a;var d=be(s.text,null,e.options.tabSize);(i==null||r>d)&&(i=a-1,r=d)}return i}function ma(e,t){if(e.modeFrontier=Math.min(e.modeFrontier,t),!(e.highlightFrontier<t-10)){for(var n=e.first,r=t-1;r>n;r--){var i=B(e,r).stateAfter;if(i&&(!(i instanceof Fn)||r+i.lookAhead<t)){n=r+1;break}}e.highlightFrontier=Math.min(e.highlightFrontier,n)}}var go=!1,jt=!1;function ya(){go=!0}function ba(){jt=!0}function In(e,t,n){this.marker=e,this.from=t,this.to=n}function rn(e,t){if(e)for(var n=0;n<e.length;++n){var r=e[n];if(r.marker==t)return r}}function xa(e,t){for(var n,r=0;r<e.length;++r)e[r]!=t&&(n||(n=[])).push(e[r]);return n}function wa(e,t){e.markedSpans=e.markedSpans?e.markedSpans.concat([t]):[t],t.marker.attachLine(e)}function ka(e,t,n){var r;if(e)for(var i=0;i<e.length;++i){var o=e[i],l=o.marker,a=o.from==null||(l.inclusiveLeft?o.from<=t:o.from<t);if(a||o.from==t&&l.type=="bookmark"&&(!n||!o.marker.insertLeft)){var s=o.to==null||(l.inclusiveRight?o.to>=t:o.to>t);(r||(r=[])).push(new In(l,o.from,s?null:o.to))}}return r}function Sa(e,t,n){var r;if(e)for(var i=0;i<e.length;++i){var o=e[i],l=o.marker,a=o.to==null||(l.inclusiveRight?o.to>=t:o.to>t);if(a||o.from==t&&l.type=="bookmark"&&(!n||o.marker.insertLeft)){var s=o.from==null||(l.inclusiveLeft?o.from<=t:o.from<t);(r||(r=[])).push(new In(l,s?null:o.from-t,o.to==null?null:o.to-t))}}return r}function gi(e,t){if(t.full)return null;var n=p(e,t.from.line)&&B(e,t.from.line).markedSpans,r=p(e,t.to.line)&&B(e,t.to.line).markedSpans;if(!n&&!r)return null;var i=t.from.ch,o=t.to.ch,l=M(t.from,t.to)==0,a=ka(n,i,l),s=Sa(r,o,l),u=t.text.length==1,d=ee(t.text).length+(u?i:0);if(a)for(var h=0;h<a.length;++h){var m=a[h];if(m.to==null){var g=rn(s,m.marker);g?u&&(m.to=g.to==null?null:g.to+d):m.to=i}}if(s)for(var b=0;b<s.length;++b){var S=s[b];if(S.to!=null&&(S.to+=d),S.from==null){var C=rn(a,S.marker);C||(S.from=d,u&&(a||(a=[])).push(S))}else S.from+=d,u&&(a||(a=[])).push(S)}a&&(a=mo(a)),s&&s!=a&&(s=mo(s));var N=[a];if(!u){var O=t.text.length-2,A;if(O>0&&a)for(var W=0;W<a.length;++W)a[W].to==null&&(A||(A=[])).push(new In(a[W].marker,null,null));for(var q=0;q<O;++q)N.push(A);N.push(s)}return N}function mo(e){for(var t=0;t<e.length;++t){var n=e[t];n.from!=null&&n.from==n.to&&n.marker.clearWhenEmpty!==!1&&e.splice(t--,1)}return e.length?e:null}function Ca(e,t,n){var r=null;if(e.iter(t.line,n.line+1,function(g){if(g.markedSpans)for(var b=0;b<g.markedSpans.length;++b){var S=g.markedSpans[b].marker;S.readOnly&&(!r||E(r,S)==-1)&&(r||(r=[])).push(S)}}),!r)return null;for(var i=[{from:t,to:n}],o=0;o<r.length;++o)for(var l=r[o],a=l.find(0),s=0;s<i.length;++s){var u=i[s];if(!(M(u.to,a.from)<0||M(u.from,a.to)>0)){var d=[s,1],h=M(u.from,a.from),m=M(u.to,a.to);(h<0||!l.inclusiveLeft&&!h)&&d.push({from:u.from,to:a.from}),(m>0||!l.inclusiveRight&&!m)&&d.push({from:a.to,to:u.to}),i.splice.apply(i,d),s+=d.length-3}}return i}function yo(e){var t=e.markedSpans;if(!!t){for(var n=0;n<t.length;++n)t[n].marker.detachLine(e);e.markedSpans=null}}function bo(e,t){if(!!t){for(var n=0;n<t.length;++n)t[n].marker.attachLine(e);e.markedSpans=t}}function Bn(e){return e.inclusiveLeft?-1:0}function Rn(e){return e.inclusiveRight?1:0}function mi(e,t){var n=e.lines.length-t.lines.length;if(n!=0)return n;var r=e.find(),i=t.find(),o=M(r.from,i.from)||Bn(e)-Bn(t);if(o)return-o;var l=M(r.to,i.to)||Rn(e)-Rn(t);return l||t.id-e.id}function xo(e,t){var n=jt&&e.markedSpans,r;if(n)for(var i=void 0,o=0;o<n.length;++o)i=n[o],i.marker.collapsed&&(t?i.from:i.to)==null&&(!r||mi(r,i.marker)<0)&&(r=i.marker);return r}function wo(e){return xo(e,!0)}function Kn(e){return xo(e,!1)}function La(e,t){var n=jt&&e.markedSpans,r;if(n)for(var i=0;i<n.length;++i){var o=n[i];o.marker.collapsed&&(o.from==null||o.from<t)&&(o.to==null||o.to>t)&&(!r||mi(r,o.marker)<0)&&(r=o.marker)}return r}function ko(e,t,n,r,i){var o=B(e,t),l=jt&&o.markedSpans;if(l)for(var a=0;a<l.length;++a){var s=l[a];if(!!s.marker.collapsed){var u=s.marker.find(0),d=M(u.from,n)||Bn(s.marker)-Bn(i),h=M(u.to,r)||Rn(s.marker)-Rn(i);if(!(d>=0&&h<=0||d<=0&&h>=0)&&(d<=0&&(s.marker.inclusiveRight&&i.inclusiveLeft?M(u.to,n)>=0:M(u.to,n)>0)||d>=0&&(s.marker.inclusiveRight&&i.inclusiveLeft?M(u.from,r)<=0:M(u.from,r)<0)))return!0}}}function Ft(e){for(var t;t=wo(e);)e=t.find(-1,!0).line;return e}function Ta(e){for(var t;t=Kn(e);)e=t.find(1,!0).line;return e}function Ma(e){for(var t,n;t=Kn(e);)e=t.find(1,!0).line,(n||(n=[])).push(e);return n}function yi(e,t){var n=B(e,t),r=Ft(n);return n==r?t:ae(r)}function So(e,t){if(t>e.lastLine())return t;var n=B(e,t),r;if(!tr(e,n))return t;for(;r=Kn(n);)n=r.find(1,!0).line;return ae(n)+1}function tr(e,t){var n=jt&&t.markedSpans;if(n){for(var r=void 0,i=0;i<n.length;++i)if(r=n[i],!!r.marker.collapsed){if(r.from==null)return!0;if(!r.marker.widgetNode&&r.from==0&&r.marker.inclusiveLeft&&bi(e,t,r))return!0}}}function bi(e,t,n){if(n.to==null){var r=n.marker.find(1,!0);return bi(e,r.line,rn(r.line.markedSpans,n.marker))}if(n.marker.inclusiveRight&&n.to==t.text.length)return!0;for(var i=void 0,o=0;o<t.markedSpans.length;++o)if(i=t.markedSpans[o],i.marker.collapsed&&!i.marker.widgetNode&&i.from==n.to&&(i.to==null||i.to!=n.from)&&(i.marker.inclusiveLeft||n.marker.inclusiveRight)&&bi(e,t,i))return!0}function Zt(e){e=Ft(e);for(var t=0,n=e.parent,r=0;r<n.lines.length;++r){var i=n.lines[r];if(i==e)break;t+=i.height}for(var o=n.parent;o;n=o,o=n.parent)for(var l=0;l<o.children.length;++l){var a=o.children[l];if(a==n)break;t+=a.height}return t}function _n(e){if(e.height==0)return 0;for(var t=e.text.length,n,r=e;n=wo(r);){var i=n.find(0,!0);r=i.from.line,t+=i.from.ch-i.to.ch}for(r=e;n=Kn(r);){var o=n.find(0,!0);t-=r.text.length-o.from.ch,r=o.to.line,t+=r.text.length-o.to.ch}return t}function xi(e){var t=e.display,n=e.doc;t.maxLine=B(n,n.first),t.maxLineLength=_n(t.maxLine),t.maxLineChanged=!0,n.iter(function(r){var i=_n(r);i>t.maxLineLength&&(t.maxLineLength=i,t.maxLine=r)})}var Dr=function(e,t,n){this.text=e,bo(this,t),this.height=n?n(this):1};Dr.prototype.lineNo=function(){return ae(this)},$t(Dr);function Na(e,t,n,r){e.text=t,e.stateAfter&&(e.stateAfter=null),e.styles&&(e.styles=null),e.order!=null&&(e.order=null),yo(e),bo(e,n);var i=r?r(e):1;i!=e.height&&St(e,i)}function Aa(e){e.parent=null,yo(e)}var Da={},Oa={};function Co(e,t){if(!e||/^\s*$/.test(e))return null;var n=t.addModeClass?Oa:Da;return n[e]||(n[e]=e.replace(/\S+/g,"cm-$&"))}function Lo(e,t){var n=D("span",null,null,se?"padding-right: .1px":null),r={pre:D("pre",[n],"CodeMirror-line"),content:n,col:0,pos:0,cm:e,trailingSpace:!1,splitSpaces:e.getOption("lineWrapping")};t.measure={};for(var i=0;i<=(t.rest?t.rest.length:0);i++){var o=i?t.rest[i-1]:t.line,l=void 0;r.pos=0,r.addToken=Pa,di(e.display.measure)&&(l=nt(o,e.doc.direction))&&(r.addToken=Ha(r.addToken,l)),r.map=[];var a=t!=e.display.externalMeasured&&ae(o);Ea(o,r,uo(e,o,a)),o.styleClasses&&(o.styleClasses.bgClass&&(r.bgClass=xt(o.styleClasses.bgClass,r.bgClass||"")),o.styleClasses.textClass&&(r.textClass=xt(o.styleClasses.textClass,r.textClass||""))),r.map.length==0&&r.map.push(0,0,r.content.appendChild(zn(e.display.measure))),i==0?(t.measure.map=r.map,t.measure.cache={}):((t.measure.maps||(t.measure.maps=[])).push(r.map),(t.measure.caches||(t.measure.caches=[])).push({}))}if(se){var s=r.content.lastChild;(/\bcm-tab\b/.test(s.className)||s.querySelector&&s.querySelector(".cm-tab"))&&(r.content.className="cm-tab-wrap-hack")}return Me(e,"renderLine",e,t.line,r.pre),r.pre.className&&(r.textClass=xt(r.pre.className,r.textClass||"")),r}function Wa(e){var t=c("span","\u2022","cm-invalidchar");return t.title="\\u"+e.charCodeAt(0).toString(16),t.setAttribute("aria-label",t.title),t}function Pa(e,t,n,r,i,o,l){if(!!t){var a=e.splitSpaces?za(t,e.trailingSpace):t,s=e.cm.state.specialChars,u=!1,d;if(!s.test(t))e.col+=t.length,d=document.createTextNode(a),e.map.push(e.pos,e.pos+t.length,d),P&&I<9&&(u=!0),e.pos+=t.length;else{d=document.createDocumentFragment();for(var h=0;;){s.lastIndex=h;var m=s.exec(t),g=m?m.index-h:t.length-h;if(g){var b=document.createTextNode(a.slice(h,h+g));P&&I<9?d.appendChild(c("span",[b])):d.appendChild(b),e.map.push(e.pos,e.pos+g,b),e.col+=g,e.pos+=g}if(!m)break;h+=g+1;var S=void 0;if(m[0]==" "){var C=e.cm.options.tabSize,N=C-e.col%C;S=d.appendChild(c("span",Ct(N),"cm-tab")),S.setAttribute("role","presentation"),S.setAttribute("cm-text"," "),e.col+=N}else m[0]=="\r"||m[0]==` diff --git a/CTFd/themes/admin/static/assets/pages/challenge.97ad70d6.js b/CTFd/themes/admin/static/assets/pages/challenge.5425c3a4.js similarity index 52% rename from CTFd/themes/admin/static/assets/pages/challenge.97ad70d6.js rename to CTFd/themes/admin/static/assets/pages/challenge.5425c3a4.js index f6707556257473c18116135103876c87ec1c6538..494e9ce3eae332b63fcec4999faa902c6f4d9a72 100644 --- a/CTFd/themes/admin/static/assets/pages/challenge.97ad70d6.js +++ b/CTFd/themes/admin/static/assets/pages/challenge.5425c3a4.js @@ -1,4 +1,4 @@ -import{_ as _export_sfc,$ as $$1,C as CTFd$1,n as nunjucks,o as openBlock,c as createElementBlock,a as createBaseVNode,F as Fragment,r as renderList,t as toDisplayString,w as withModifiers,b as createCommentVNode,d as createStaticVNode,e as resolveComponent,f as createVNode,g as withCtx,T as TransitionGroup,h as withDirectives,v as vModelSelect,i as vModelCheckbox,j as createTextVNode,p as pushScopeId,k as popScopeId,l as vModelText,m as withKeys,q as normalizeClass,s as helpers,u as ezQuery,x as vShow,y as bindMarkdownEditor,z as htmlEntities,V as Vue$1,A as bindMarkdownEditors,B as ezAlert,D as ezToast}from"./main.9b987665.js";import"../tab.39c73246.js";import{C as CommentBox}from"../CommentBox.d08ed1e6.js";const _sfc_main$b={name:"FlagCreationForm",props:{challenge_id:Number},data:function(){return{types:{},selectedType:null,createForm:""}},methods:{selectType:function(event){let flagType=event.target.value;if(this.types[flagType]===void 0){this.selectedType=null,this.createForm="";return}let createFormURL=this.types[flagType].templates.create;$$1.get(CTFd$1.config.urlRoot+createFormURL,template_data=>{const template=nunjucks.compile(template_data);this.selectedType=flagType,this.createForm=template.render(),this.createForm.includes("<script")&&setTimeout(()=>{$$1("<div>"+this.createForm+"</div>").find("script").each(function(){eval($$1(this).html())})},100)})},loadTypes:function(){CTFd$1.fetch("/api/v1/flags/types",{method:"GET"}).then(e=>e.json()).then(e=>{this.types=e.data})},submitFlag:function(e){let n=$$1(e.target).serializeJSON(!0);n.challenge=this.$props.challenge_id,CTFd$1.fetch("/api/v1/flags",{method:"POST",credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"},body:JSON.stringify(n)}).then(i=>i.json()).then(i=>{this.$emit("refreshFlags",this.$options.name)})}},created(){this.loadTypes()}},_hoisted_1$b={id:"flag-create-modal",class:"modal fade",tabindex:"-1"},_hoisted_2$b={class:"modal-dialog modal-lg"},_hoisted_3$b={class:"modal-content"},_hoisted_4$b=createStaticVNode('<div class="modal-header text-center"><div class="container"><div class="row"><div class="col-md-12"><h3>Create Answer</h3></div></div></div><button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">\xD7</span></button></div>',1),_hoisted_5$b={class:"modal-body"},_hoisted_6$a={class:"create-keys-select-div"},_hoisted_7$8=createBaseVNode("label",{for:"create-keys-select",class:"control-label"}," Choose Answer Type ",-1),_hoisted_8$8=createBaseVNode("option",null,"--",-1),_hoisted_9$7=["value"],_hoisted_10$6=createBaseVNode("br",null,null,-1),_hoisted_11$5=["innerHTML"],_hoisted_12$5={key:0,class:"btn btn-secondary float-right",type:"submit"};function _sfc_render$b(e,t,n,i,a,o){return openBlock(),createElementBlock("div",_hoisted_1$b,[createBaseVNode("div",_hoisted_2$b,[createBaseVNode("div",_hoisted_3$b,[_hoisted_4$b,createBaseVNode("div",_hoisted_5$b,[createBaseVNode("div",_hoisted_6$a,[_hoisted_7$8,createBaseVNode("select",{class:"form-control custom-select",onChange:t[0]||(t[0]=s=>o.selectType(s))},[_hoisted_8$8,(openBlock(!0),createElementBlock(Fragment,null,renderList(Object.keys(e.types),s=>(openBlock(),createElementBlock("option",{value:s,key:s},toDisplayString(s),9,_hoisted_9$7))),128))],32)]),_hoisted_10$6,createBaseVNode("form",{onSubmit:t[1]||(t[1]=withModifiers((...s)=>o.submitFlag&&o.submitFlag(...s),["prevent"]))},[createBaseVNode("div",{id:"create-flag-form",innerHTML:e.createForm},null,8,_hoisted_11$5),e.createForm?(openBlock(),createElementBlock("button",_hoisted_12$5," Create Answer ")):createCommentVNode("",!0)],32)])])])])}const FlagCreationForm=_export_sfc(_sfc_main$b,[["render",_sfc_render$b]]),_sfc_main$a={name:"FlagEditForm",props:{flag_id:Number},data:function(){return{flag:{},editForm:""}},watch:{flag_id:{immediate:!0,handler(e,t){e!==null&&this.loadFlag()}}},methods:{loadFlag:function(){CTFd$1.fetch(`/api/v1/flags/${this.$props.flag_id}`,{method:"GET"}).then(e=>e.json()).then(response=>{this.flag=response.data;let editFormURL=this.flag.templates.update;$$1.get(CTFd$1.config.urlRoot+editFormURL,template_data=>{const template=nunjucks.compile(template_data);this.editForm=template.render(this.flag),this.editForm.includes("<script")&&setTimeout(()=>{$$1("<div>"+this.editForm+"</div>").find("script").each(function(){eval($$1(this).html())})},100)})})},updateFlag:function(e){let n=$$1(e.target).serializeJSON(!0);CTFd$1.fetch(`/api/v1/flags/${this.$props.flag_id}`,{method:"PATCH",credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"},body:JSON.stringify(n)}).then(i=>i.json()).then(i=>{this.$emit("refreshFlags",this.$options.name)})}},mounted(){this.flag_id&&this.loadFlag()},created(){this.flag_id&&this.loadFlag()}},_hoisted_1$a={id:"flag-edit-modal",class:"modal fade",tabindex:"-1"},_hoisted_2$a={class:"modal-dialog modal-lg"},_hoisted_3$a={class:"modal-content"},_hoisted_4$a=createStaticVNode('<div class="modal-header text-center"><div class="container"><div class="row"><div class="col-md-12"><h3 class="text-center">Edit Flag</h3></div></div></div><button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">\xD7</span></button></div>',1),_hoisted_5$a={class:"modal-body"},_hoisted_6$9=["innerHTML"];function _sfc_render$a(e,t,n,i,a,o){return openBlock(),createElementBlock("div",_hoisted_1$a,[createBaseVNode("div",_hoisted_2$a,[createBaseVNode("div",_hoisted_3$a,[_hoisted_4$a,createBaseVNode("div",_hoisted_5$a,[createBaseVNode("form",{method:"POST",innerHTML:e.editForm,onSubmit:t[0]||(t[0]=withModifiers((...s)=>o.updateFlag&&o.updateFlag(...s),["prevent"]))},null,40,_hoisted_6$9)])])])])}const FlagEditForm=_export_sfc(_sfc_main$a,[["render",_sfc_render$a]]),_sfc_main$9={components:{FlagCreationForm,FlagEditForm},props:{challenge_id:Number},data:function(){return{flags:[],editing_flag_id:null}},methods:{loadFlags:function(){CTFd$1.fetch(`/api/v1/challenges/${this.$props.challenge_id}/flags`,{method:"GET",credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"}}).then(e=>e.json()).then(e=>{e.success&&(this.flags=e.data)})},refreshFlags(e){this.loadFlags();let t;switch(e){case"FlagEditForm":t=this.$refs.FlagEditForm.$el,$$1(t).modal("hide");break;case"FlagCreationForm":t=this.$refs.FlagCreationForm.$el,$$1(t).modal("hide");break}},addFlag:function(){let e=this.$refs.FlagCreationForm.$el;$$1(e).modal()},editFlag:function(e){this.editing_flag_id=e;let t=this.$refs.FlagEditForm.$el;$$1(t).modal()},deleteFlag:function(e){confirm("Are you sure you'd like to delete this flag?")&&CTFd$1.fetch(`/api/v1/flags/${e}`,{method:"DELETE"}).then(t=>t.json()).then(t=>{t.success&&this.loadFlags()})}},created(){this.loadFlags()}},_hoisted_1$9={id:"flagsboard",class:"table table-striped"},_hoisted_2$9=createBaseVNode("thead",null,[createBaseVNode("tr",null,[createBaseVNode("td",{class:"text-center"},[createBaseVNode("b",null,"Type")]),createBaseVNode("td",{class:"text-center"},[createBaseVNode("b",null,"Answer")]),createBaseVNode("td",{class:"text-center"},[createBaseVNode("b",null,"Settings")])])],-1),_hoisted_3$9=["name"],_hoisted_4$9={class:"text-center"},_hoisted_5$9={class:"text-break"},_hoisted_6$8={class:"flag-content"},_hoisted_7$7={class:"text-center"},_hoisted_8$7=["flag-id","flag-type","onClick"],_hoisted_9$6=["flag-id","onClick"],_hoisted_10$5=createBaseVNode("td",{class:"text-center"},null,-1),_hoisted_11$4=createBaseVNode("td",{class:"text-break"},null,-1),_hoisted_12$4={class:"text-center"};function _sfc_render$9(e,t,n,i,a,o){const s=resolveComponent("FlagCreationForm"),l=resolveComponent("FlagEditForm");return openBlock(),createElementBlock("div",null,[createBaseVNode("div",null,[createVNode(s,{ref:"FlagCreationForm",challenge_id:n.challenge_id,onRefreshFlags:o.refreshFlags},null,8,["challenge_id","onRefreshFlags"])]),createBaseVNode("div",null,[createVNode(l,{ref:"FlagEditForm",flag_id:e.editing_flag_id,onRefreshFlags:o.refreshFlags},null,8,["flag_id","onRefreshFlags"])]),createBaseVNode("table",_hoisted_1$9,[_hoisted_2$9,createBaseVNode("tbody",null,[(openBlock(!0),createElementBlock(Fragment,null,renderList(e.flags,d=>(openBlock(),createElementBlock("tr",{name:d.id,key:d.id},[createBaseVNode("td",_hoisted_4$9,toDisplayString(d.type),1),createBaseVNode("td",_hoisted_5$9,[createBaseVNode("pre",_hoisted_6$8,toDisplayString(d.content),1)]),createBaseVNode("td",_hoisted_7$7,[createBaseVNode("i",{role:"button",class:"btn-fa fas fa-edit edit-flag","flag-id":d.id,"flag-type":d.type,onClick:c=>o.editFlag(d.id)},null,8,_hoisted_8$7),createBaseVNode("i",{role:"button",class:"btn-fa fas fa-times delete-flag","flag-id":d.id,onClick:c=>o.deleteFlag(d.id)},null,8,_hoisted_9$6)])],8,_hoisted_3$9))),128)),createBaseVNode("tr",null,[_hoisted_10$5,_hoisted_11$4,createBaseVNode("td",_hoisted_12$4,[createBaseVNode("i",{id:"flag-add-button",class:"btn-fa fas fa-plus add-flag",onClick:t[0]||(t[0]=d=>o.addFlag())})])])])])])}const FlagList=_export_sfc(_sfc_main$9,[["render",_sfc_render$9]]),Requirements_vue_vue_type_style_index_0_scoped_3c612631_lang="",_sfc_main$8={props:{challenge_id:Number},data:function(){return{challenges:[],requirements:{},selectedRequirements:[],selectedAnonymize:!1}},computed:{newRequirements:function(){let e=this.requirements.prerequisites||[],t=this.requirements.anonymize||!1,n=JSON.stringify(e.sort())!==JSON.stringify(this.selectedRequirements.sort()),i=t!==this.selectedAnonymize;return n||i},requiredChallenges:function(){const e=this.requirements.prerequisites||[];return this.challenges.filter(t=>t.id!==this.$props.challenge_id&&e.includes(t.id))},otherChallenges:function(){const e=this.requirements.prerequisites||[];return this.challenges.filter(t=>t.id!==this.$props.challenge_id&&!e.includes(t.id))}},methods:{loadChallenges:function(){CTFd$1.fetch("/api/v1/challenges?view=admin",{method:"GET",credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"}}).then(e=>e.json()).then(e=>{e.success&&(this.challenges=e.data)})},getChallengeNameById:function(e){let t=this.challenges.find(n=>n.id===e);return t?t.name:""},loadRequirements:function(){CTFd$1.fetch(`/api/v1/challenges/${this.$props.challenge_id}/requirements`,{method:"GET",credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"}}).then(e=>e.json()).then(e=>{e.success&&(this.requirements=e.data||{},this.selectedRequirements=this.requirements.prerequisites||[],this.selectedAnonymize=this.requirements.anonymize||!1)})},updateRequirements:function(){const t={requirements:{prerequisites:this.selectedRequirements}};this.selectedAnonymize&&(t.requirements.anonymize=!0),CTFd$1.fetch(`/api/v1/challenges/${this.$props.challenge_id}`,{method:"PATCH",credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"},body:JSON.stringify(t)}).then(n=>n.json()).then(n=>{n.success&&this.loadRequirements()})}},created(){this.loadChallenges(),this.loadRequirements()}},_withScopeId=e=>(pushScopeId("data-v-3c612631"),e=e(),popScopeId(),e),_hoisted_1$8={class:"form-group scrollbox"},_hoisted_2$8={class:"form-check-label cursor-pointer"},_hoisted_3$8=["value"],_hoisted_4$8={class:"form-check-label cursor-pointer"},_hoisted_5$8=["value"],_hoisted_6$7={class:"form-group"},_hoisted_7$6=_withScopeId(()=>createBaseVNode("label",null,[createBaseVNode("b",null,"Behavior if not unlocked")],-1)),_hoisted_8$6=_withScopeId(()=>createBaseVNode("option",{value:!1},"Cach\xE9",-1)),_hoisted_9$5=_withScopeId(()=>createBaseVNode("option",{value:!0},"Anonymized",-1)),_hoisted_10$4=[_hoisted_8$6,_hoisted_9$5],_hoisted_11$3={class:"form-group"},_hoisted_12$3=["disabled"];function _sfc_render$8(e,t,n,i,a,o){return openBlock(),createElementBlock("div",null,[createBaseVNode("form",{onSubmit:t[3]||(t[3]=withModifiers((...s)=>o.updateRequirements&&o.updateRequirements(...s),["prevent"]))},[createBaseVNode("div",_hoisted_1$8,[createVNode(TransitionGroup,{name:"flip-list"},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(o.requiredChallenges,s=>(openBlock(),createElementBlock("div",{class:"form-check",key:s.id},[createBaseVNode("label",_hoisted_2$8,[withDirectives(createBaseVNode("input",{class:"form-check-input",type:"checkbox",value:s.id,"onUpdate:modelValue":t[0]||(t[0]=l=>e.selectedRequirements=l)},null,8,_hoisted_3$8),[[vModelCheckbox,e.selectedRequirements]]),createTextVNode(" "+toDisplayString(s.name),1)])]))),128)),(openBlock(!0),createElementBlock(Fragment,null,renderList(o.otherChallenges,s=>(openBlock(),createElementBlock("div",{class:"form-check",key:s.id},[createBaseVNode("label",_hoisted_4$8,[withDirectives(createBaseVNode("input",{class:"form-check-input",type:"checkbox",value:s.id,"onUpdate:modelValue":t[1]||(t[1]=l=>e.selectedRequirements=l)},null,8,_hoisted_5$8),[[vModelCheckbox,e.selectedRequirements]]),createTextVNode(" "+toDisplayString(s.name),1)])]))),128))]),_:1})]),createBaseVNode("div",_hoisted_6$7,[_hoisted_7$6,withDirectives(createBaseVNode("select",{class:"form-control custom-select",name:"anonymize","onUpdate:modelValue":t[2]||(t[2]=s=>e.selectedAnonymize=s)},_hoisted_10$4,512),[[vModelSelect,e.selectedAnonymize]])]),createBaseVNode("div",_hoisted_11$3,[createBaseVNode("button",{class:"btn btn-success float-right",disabled:!o.newRequirements}," Save ",8,_hoisted_12$3)])],32)])}const Requirements=_export_sfc(_sfc_main$8,[["render",_sfc_render$8],["__scopeId","data-v-3c612631"]]),_sfc_main$7={props:{challenge_id:Number},data:function(){return{topics:[],topicValue:"",searchedTopic:"",topicResults:[],selectedResultIdx:0,awaitingSearch:!1}},methods:{loadTopics:function(){CTFd$1.fetch(`/api/v1/challenges/${this.$props.challenge_id}/topics`,{method:"GET",credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"}}).then(e=>e.json()).then(e=>{e.success&&(this.topics=e.data)})},searchTopics:function(){if(this.selectedResultIdx=0,this.topicValue==""){this.topicResults=[];return}CTFd$1.fetch(`/api/v1/topics?field=value&q=${this.topicValue}`,{method:"GET",credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"}}).then(e=>e.json()).then(e=>{e.success&&(this.topicResults=e.data.slice(0,10))})},addTopic:function(){let e;if(this.selectedResultIdx===0)e=this.topicValue;else{let n=this.selectedResultIdx-1;e=this.topicResults[n].value}const t={value:e,challenge:this.$props.challenge_id,type:"challenge"};CTFd$1.fetch("/api/v1/topics",{method:"POST",body:JSON.stringify(t)}).then(n=>n.json()).then(n=>{n.success&&(this.topicValue="",this.loadTopics())})},deleteTopic:function(e){CTFd$1.fetch(`/api/v1/topics?type=challenge&target_id=${e}`,{method:"DELETE"}).then(t=>t.json()).then(t=>{t.success&&this.loadTopics()})},moveCursor:function(e){switch(e){case"up":this.selectedResultIdx&&(this.selectedResultIdx-=1);break;case"down":this.selectedResultIdx<this.topicResults.length&&(this.selectedResultIdx+=1);break}},selectTopic:function(e){e===void 0&&(e=this.selectedResultIdx);let t=this.topicResults[e];this.topicValue=t.value}},watch:{topicValue:function(e){this.awaitingSearch===!1&&setTimeout(()=>{this.searchTopics(),this.awaitingSearch=!1},500),this.awaitingSearch=!0}},created(){this.loadTopics()}},_hoisted_1$7={class:"col-md-12"},_hoisted_2$7={id:"challenge-topics",class:"my-3"},_hoisted_3$7={class:"mr-1"},_hoisted_4$7=["onClick"],_hoisted_5$7={class:"form-group"},_hoisted_6$6=createBaseVNode("label",null,[createTextVNode(" Topic "),createBaseVNode("br"),createBaseVNode("small",{class:"text-muted"},"Type topic and press Enter")],-1),_hoisted_7$5={class:"form-group"},_hoisted_8$5={class:"list-group"},_hoisted_9$4=["onClick"];function _sfc_render$7(e,t,n,i,a,o){return openBlock(),createElementBlock("div",_hoisted_1$7,[createBaseVNode("div",_hoisted_2$7,[(openBlock(!0),createElementBlock(Fragment,null,renderList(e.topics,s=>(openBlock(),createElementBlock("h5",{class:"challenge-tag",key:s.id},[createBaseVNode("span",_hoisted_3$7,toDisplayString(s.value),1),createBaseVNode("a",{class:"btn-fa delete-tag",onClick:l=>o.deleteTopic(s.id)}," \xD7",8,_hoisted_4$7)]))),128))]),createBaseVNode("div",_hoisted_5$7,[_hoisted_6$6,withDirectives(createBaseVNode("input",{id:"tags-add-input",maxlength:"255",type:"text",class:"form-control","onUpdate:modelValue":t[0]||(t[0]=s=>e.topicValue=s),onKeyup:[t[1]||(t[1]=withKeys(s=>o.moveCursor("down"),["down"])),t[2]||(t[2]=withKeys(s=>o.moveCursor("up"),["up"])),t[3]||(t[3]=withKeys(s=>o.addTopic(),["enter"]))]},null,544),[[vModelText,e.topicValue]])]),createBaseVNode("div",_hoisted_7$5,[createBaseVNode("ul",_hoisted_8$5,[(openBlock(!0),createElementBlock(Fragment,null,renderList(e.topicResults,(s,l)=>(openBlock(),createElementBlock("li",{class:normalizeClass({"list-group-item":!0,active:l+1===e.selectedResultIdx}),key:s.id,onClick:d=>o.selectTopic(l)},toDisplayString(s.value),11,_hoisted_9$4))),128))])])])}const TopicsList=_export_sfc(_sfc_main$7,[["render",_sfc_render$7]]),_sfc_main$6={props:{challenge_id:Number},data:function(){return{tags:[],tagValue:""}},methods:{loadTags:function(){CTFd$1.fetch(`/api/v1/challenges/${this.$props.challenge_id}/tags`,{method:"GET",credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"}}).then(e=>e.json()).then(e=>{e.success&&(this.tags=e.data)})},addTag:function(){if(this.tagValue){const e={value:this.tagValue,challenge:this.$props.challenge_id};CTFd$1.api.post_tag_list({},e).then(t=>{t.success&&(this.tagValue="",this.loadTags())})}},deleteTag:function(e){CTFd$1.api.delete_tag({tagId:e}).then(t=>{t.success&&this.loadTags()})}},created(){this.loadTags()}},_hoisted_1$6={class:"col-md-12"},_hoisted_2$6={id:"challenge-tags",class:"my-3"},_hoisted_3$6=["onClick"],_hoisted_4$6={class:"form-group"},_hoisted_5$6=createBaseVNode("label",null,[createTextVNode("Tag "),createBaseVNode("br"),createBaseVNode("small",{class:"text-muted"},"Type tag and press Enter")],-1);function _sfc_render$6(e,t,n,i,a,o){return openBlock(),createElementBlock("div",_hoisted_1$6,[createBaseVNode("div",_hoisted_2$6,[(openBlock(!0),createElementBlock(Fragment,null,renderList(e.tags,s=>(openBlock(),createElementBlock("span",{class:"badge badge-primary mx-1 challenge-tag",key:s.id},[createBaseVNode("span",null,toDisplayString(s.value),1),createBaseVNode("a",{class:"btn-fa delete-tag",onClick:l=>o.deleteTag(s.id)}," \xD7",8,_hoisted_3$6)]))),128))]),createBaseVNode("div",_hoisted_4$6,[_hoisted_5$6,withDirectives(createBaseVNode("input",{id:"tags-add-input",maxlength:"80",type:"text",class:"form-control","onUpdate:modelValue":t[0]||(t[0]=s=>e.tagValue=s),onKeyup:t[1]||(t[1]=withKeys(s=>o.addTag(),["enter"]))},null,544),[[vModelText,e.tagValue]])])])}const TagsList=_export_sfc(_sfc_main$6,[["render",_sfc_render$6]]),_sfc_main$5={props:{challenge_id:Number},data:function(){return{files:[],urlRoot:CTFd$1.config.urlRoot}},methods:{loadFiles:function(){CTFd$1.fetch(`/api/v1/challenges/${this.$props.challenge_id}/files`,{method:"GET"}).then(e=>e.json()).then(e=>{e.success&&(this.files=e.data)})},addFiles:function(){let e={challenge:this.$props.challenge_id,type:"challenge"},t=this.$refs.FileUploadForm;helpers.files.upload(t,e,n=>{setTimeout(()=>{this.loadFiles()},700)})},deleteFile:function(e){ezQuery({title:"Delete Files",body:"\xCAtes-vous certain de vouloir supprimer this file?",success:()=>{CTFd$1.fetch(`/api/v1/files/${e}`,{method:"DELETE"}).then(t=>t.json()).then(t=>{t.success&&this.loadFiles()})}})}},created(){this.loadFiles()}},_hoisted_1$5={id:"filesboard",class:"table table-striped"},_hoisted_2$5=createBaseVNode("thead",null,[createBaseVNode("tr",null,[createBaseVNode("td",{class:"text-center"},[createBaseVNode("b",null,"File")]),createBaseVNode("td",{class:"text-center"},[createBaseVNode("b",null,"Settings")])])],-1),_hoisted_3$5={class:"text-center"},_hoisted_4$5=["href"],_hoisted_5$5={class:"text-center"},_hoisted_6$5=["onClick"],_hoisted_7$4={class:"col-md-12 mt-3"},_hoisted_8$4=createStaticVNode('<div class="form-group"><input class="form-control-file" id="file" multiple="" name="file" required="" type="file"><sub class="text-muted"> Attach multiple files using CTRL+Click or Cmd+Click. </sub></div><div class="form-group"><input class="btn btn-success float-right" id="_submit" name="_submit" type="submit" value="Upload"></div>',2),_hoisted_10$3=[_hoisted_8$4];function _sfc_render$5(e,t,n,i,a,o){return openBlock(),createElementBlock("div",null,[createBaseVNode("table",_hoisted_1$5,[_hoisted_2$5,createBaseVNode("tbody",null,[(openBlock(!0),createElementBlock(Fragment,null,renderList(e.files,s=>(openBlock(),createElementBlock("tr",{key:s.id},[createBaseVNode("td",_hoisted_3$5,[createBaseVNode("a",{href:`${e.urlRoot}/files/${s.location}`},toDisplayString(s.location.split("/").pop()),9,_hoisted_4$5)]),createBaseVNode("td",_hoisted_5$5,[createBaseVNode("i",{role:"button",class:"btn-fa fas fa-times delete-file",onClick:l=>o.deleteFile(s.id)},null,8,_hoisted_6$5)])]))),128))])]),createBaseVNode("div",_hoisted_7$4,[createBaseVNode("form",{method:"POST",ref:"FileUploadForm",onSubmit:t[0]||(t[0]=withModifiers((...s)=>o.addFiles&&o.addFiles(...s),["prevent"]))},_hoisted_10$3,544)])])}const ChallengeFilesList=_export_sfc(_sfc_main$5,[["render",_sfc_render$5]]),_sfc_main$4={props:{challengeId:Number,challengeName:String,CHALLENGE_THUMBSNAIL:String},data:function(){return{files:[],urlRoot:CTFd$1.config.urlRoot}},methods:{updateThumbsnailPath(e){CTFd$1.fetch(`/api/v1/challenges/${CHALLENGE_ID}/thumbsnail`,{method:"PATCH",headers:{"Content-Type":"application/json"},body:JSON.stringify({thumbsnail:e})}).then(t=>t.json()).then(t=>{t.success?console.log("Thumbsnail path updated successfully."):console.error("Failed to update thumbsnail path:",t.message)})}},mounted(){document.getElementById("btn-file-input").style.display="block",document.getElementById("btn-file-input").addEventListener("click",()=>{document.getElementById("thumbsnail-get-path").click()}),document.getElementById("thumbsnail-get-path").addEventListener("change",e=>{const t=e.target.files[0];let n=document.getElementById("thumbsnail-upload-form");const i=new FormData(n);if(i.append("file",t),helpers.files.upload(i,n,a=>{const o=a.data[0],s=CTFd$1.config.urlRoot+"/files/"+o.location;document.getElementById("thumbsnail-path").value=s,console.log("Thumbnail uploaded successfully:",s);const l=document.getElementById("image-preview");l.src=s,l.style.display="block",this.updateThumbsnailPath(s)}),t){const a=new FileReader;a.onload=function(o){const s=document.getElementById("image-preview");s.src=o.target.result,s.style.display="block"},a.readAsDataURL(t)}})}},_hoisted_1$4={id:"Thumbsnailboard",class:"table table-striped"},_hoisted_2$4=createBaseVNode("thead",null,[createBaseVNode("tr",null,[createBaseVNode("td",{class:"text-center"},[createBaseVNode("b",null,"Miniature")]),createBaseVNode("td",{class:"text-center"},[createBaseVNode("b",null,"Settings")])])],-1),_hoisted_3$4={class:"text-center"},_hoisted_4$4=["href"],_hoisted_5$4={class:"text-center"},_hoisted_6$4=["onClick"],_hoisted_7$3={class:"col-md-12 mt-3"},_hoisted_8$3={id:"thumbsnail-upload-form",class:"form-upload",method:"POST",enctype:"multipart/form-data"},_hoisted_9$3=createBaseVNode("button",{id:"btn-file-input",class:"btn btn-secondary",type:"button"},"Select File",-1),_hoisted_10$2=["src"],_hoisted_11$2=createBaseVNode("input",{class:"form-control-file",id:"thumbsnail-get-path",name:"file",type:"file",accept:".png",style:{display:"none"}},null,-1),_hoisted_12$2=createBaseVNode("input",{type:"hidden",id:"thumbsnail-path",name:"thumbsnail"},null,-1);function _sfc_render$4(e,t,n,i,a,o){return openBlock(),createElementBlock("div",null,[createBaseVNode("table",_hoisted_1$4,[_hoisted_2$4,createBaseVNode("tbody",null,[(openBlock(!0),createElementBlock(Fragment,null,renderList(e.files,s=>(openBlock(),createElementBlock("tr",{key:s.id},[createBaseVNode("td",_hoisted_3$4,[createBaseVNode("a",{href:`${e.urlRoot}/files/${s.location}`},toDisplayString(s.location.split("/").pop()),9,_hoisted_4$4)]),createBaseVNode("td",_hoisted_5$4,[createBaseVNode("i",{role:"button",class:"btn-fa fas fa-times delete-file",onClick:l=>e.deleteFile(s.id)},null,8,_hoisted_6$4)])]))),128))])]),createBaseVNode("div",_hoisted_7$3,[createBaseVNode("form",_hoisted_8$3,[_hoisted_9$3,withDirectives(createBaseVNode("img",{id:"image-preview",src:n.CHALLENGE_THUMBSNAIL,style:{width:"100px",height:"100px","margin-top":"10px"}},null,8,_hoisted_10$2),[[vShow,n.CHALLENGE_THUMBSNAIL]]),_hoisted_11$2,_hoisted_12$2])])])}const ChallengeThumbsnail=_export_sfc(_sfc_main$4,[["render",_sfc_render$4]]),_sfc_main$3={name:"HintCreationForm",props:{challenge_id:Number,hints:Array},data:function(){return{cost:0,selectedHints:[]}},methods:{getCost:function(){return this.cost||0},getContent:function(){return this.$refs.content.value},submitHint:function(){let e={challenge_id:this.$props.challenge_id,content:this.getContent(),cost:this.getCost(),requirements:{prerequisites:this.selectedHints}};CTFd.fetch("/api/v1/hints",{method:"POST",credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"},body:JSON.stringify(e)}).then(t=>t.json()).then(t=>{t.success&&this.$emit("refreshHints",this.$options.name)})}}},_hoisted_1$3={class:"modal fade",tabindex:"-1"},_hoisted_2$3={class:"modal-dialog"},_hoisted_3$3={class:"modal-content"},_hoisted_4$3=createStaticVNode('<div class="modal-header text-center"><div class="container"><div class="row"><div class="col-md-12"><h3>Hint</h3></div></div></div><button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">\xD7</span></button></div>',1),_hoisted_5$3={class:"modal-body"},_hoisted_6$3={class:"container"},_hoisted_7$2={class:"row"},_hoisted_8$2={class:"col-md-12"},_hoisted_9$2={class:"form-group"},_hoisted_10$1=createBaseVNode("label",null,[createTextVNode(" Hint"),createBaseVNode("br"),createBaseVNode("small",null,"Markdown & HTML are supported")],-1),_hoisted_11$1={type:"text",class:"form-control markdown",name:"content",rows:"7",ref:"content"},_hoisted_12$1={class:"form-group"},_hoisted_13$1=createBaseVNode("label",null,[createTextVNode(" Cost"),createBaseVNode("br"),createBaseVNode("small",null,"How many points it costs to see your hint.")],-1),_hoisted_14$1={class:"form-group"},_hoisted_15$1=createBaseVNode("label",null,[createTextVNode(" Requirements"),createBaseVNode("br"),createBaseVNode("small",null,"Hints that must be unlocked before unlocking this hint")],-1),_hoisted_16$1={class:"form-check-label cursor-pointer"},_hoisted_17$1=["value"],_hoisted_18$1=createBaseVNode("input",{type:"hidden",id:"hint-id-for-hint",name:"id"},null,-1),_hoisted_19=createStaticVNode('<div class="modal-footer"><div class="container"><div class="row"><div class="col-md-12"><button class="btn btn-primary float-right">Submit</button></div></div></div></div>',1);function _sfc_render$3(e,t,n,i,a,o){return openBlock(),createElementBlock("div",_hoisted_1$3,[createBaseVNode("div",_hoisted_2$3,[createBaseVNode("div",_hoisted_3$3,[_hoisted_4$3,createBaseVNode("form",{method:"POST",onSubmit:t[2]||(t[2]=withModifiers((...s)=>o.submitHint&&o.submitHint(...s),["prevent"]))},[createBaseVNode("div",_hoisted_5$3,[createBaseVNode("div",_hoisted_6$3,[createBaseVNode("div",_hoisted_7$2,[createBaseVNode("div",_hoisted_8$2,[createBaseVNode("div",_hoisted_9$2,[_hoisted_10$1,createBaseVNode("textarea",_hoisted_11$1,null,512)]),createBaseVNode("div",_hoisted_12$1,[_hoisted_13$1,withDirectives(createBaseVNode("input",{type:"number",class:"form-control",name:"cost","onUpdate:modelValue":t[0]||(t[0]=s=>e.cost=s)},null,512),[[vModelText,e.cost,void 0,{lazy:!0}]])]),createBaseVNode("div",_hoisted_14$1,[_hoisted_15$1,(openBlock(!0),createElementBlock(Fragment,null,renderList(n.hints,s=>(openBlock(),createElementBlock("div",{class:"form-check",key:s.id},[createBaseVNode("label",_hoisted_16$1,[withDirectives(createBaseVNode("input",{class:"form-check-input",type:"checkbox",value:s.id,"onUpdate:modelValue":t[1]||(t[1]=l=>e.selectedHints=l)},null,8,_hoisted_17$1),[[vModelCheckbox,e.selectedHints]]),createTextVNode(" "+toDisplayString(s.cost)+" - "+toDisplayString(s.id),1)])]))),128))]),_hoisted_18$1])])])]),_hoisted_19],32)])])])}const HintCreationForm=_export_sfc(_sfc_main$3,[["render",_sfc_render$3]]),_sfc_main$2={name:"HintEditForm",props:{challenge_id:Number,hint_id:Number,hints:Array},data:function(){return{cost:0,content:null,selectedHints:[]}},computed:{otherHints:function(){return this.hints.filter(e=>e.id!==this.$props.hint_id)}},watch:{hint_id:{immediate:!0,handler(e,t){e!==null&&this.loadHint()}}},methods:{loadHint:function(){CTFd$1.fetch(`/api/v1/hints/${this.$props.hint_id}?preview=true`,{method:"GET",credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"}}).then(e=>e.json()).then(e=>{var t;if(e.success){let n=e.data;this.cost=n.cost,this.content=n.content,this.selectedHints=((t=n.requirements)==null?void 0:t.prerequisites)||[];let i=this.$refs.content;bindMarkdownEditor(i),setTimeout(()=>{i.mde.codemirror.getDoc().setValue(i.value),this._forceRefresh()},200)}})},_forceRefresh:function(){this.$refs.content.mde.codemirror.refresh()},getCost:function(){return this.cost||0},getContent:function(){return this._forceRefresh(),this.$refs.content.mde.codemirror.getDoc().getValue()},updateHint:function(){let e={challenge_id:this.$props.challenge_id,content:this.getContent(),cost:this.getCost(),requirements:{prerequisites:this.selectedHints}};CTFd$1.fetch(`/api/v1/hints/${this.$props.hint_id}`,{method:"PATCH",credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"},body:JSON.stringify(e)}).then(t=>t.json()).then(t=>{t.success&&this.$emit("refreshHints",this.$options.name)})}},mounted(){this.hint_id&&this.loadHint()},created(){this.hint_id&&this.loadHint()}},_hoisted_1$2={class:"modal fade",tabindex:"-1"},_hoisted_2$2={class:"modal-dialog"},_hoisted_3$2={class:"modal-content"},_hoisted_4$2=createStaticVNode('<div class="modal-header text-center"><div class="container"><div class="row"><div class="col-md-12"><h3>Hint</h3></div></div></div><button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">\xD7</span></button></div>',1),_hoisted_5$2={class:"modal-body"},_hoisted_6$2={class:"container"},_hoisted_7$1={class:"row"},_hoisted_8$1={class:"col-md-12"},_hoisted_9$1={class:"form-group"},_hoisted_10=createBaseVNode("label",null,[createTextVNode(" Hint"),createBaseVNode("br"),createBaseVNode("small",null,"Markdown & HTML are supported")],-1),_hoisted_11=["value"],_hoisted_12={class:"form-group"},_hoisted_13=createBaseVNode("label",null,[createTextVNode(" Cost"),createBaseVNode("br"),createBaseVNode("small",null,"How many points it costs to see your hint.")],-1),_hoisted_14={class:"form-group"},_hoisted_15=createBaseVNode("label",null,[createTextVNode(" Requirements"),createBaseVNode("br"),createBaseVNode("small",null,"Hints that must be unlocked before unlocking this hint")],-1),_hoisted_16={class:"form-check-label cursor-pointer"},_hoisted_17=["value"],_hoisted_18=createStaticVNode('<div class="modal-footer"><div class="container"><div class="row"><div class="col-md-12"><button class="btn btn-primary float-right">Submit</button></div></div></div></div>',1);function _sfc_render$2(e,t,n,i,a,o){return openBlock(),createElementBlock("div",_hoisted_1$2,[createBaseVNode("div",_hoisted_2$2,[createBaseVNode("div",_hoisted_3$2,[_hoisted_4$2,createBaseVNode("form",{method:"POST",onSubmit:t[2]||(t[2]=withModifiers((...s)=>o.updateHint&&o.updateHint(...s),["prevent"]))},[createBaseVNode("div",_hoisted_5$2,[createBaseVNode("div",_hoisted_6$2,[createBaseVNode("div",_hoisted_7$1,[createBaseVNode("div",_hoisted_8$1,[createBaseVNode("div",_hoisted_9$1,[_hoisted_10,createBaseVNode("textarea",{type:"text",class:"form-control",name:"content",rows:"7",value:this.content,ref:"content"},null,8,_hoisted_11)]),createBaseVNode("div",_hoisted_12,[_hoisted_13,withDirectives(createBaseVNode("input",{type:"number",class:"form-control",name:"cost","onUpdate:modelValue":t[0]||(t[0]=s=>e.cost=s)},null,512),[[vModelText,e.cost,void 0,{lazy:!0}]])]),createBaseVNode("div",_hoisted_14,[_hoisted_15,(openBlock(!0),createElementBlock(Fragment,null,renderList(o.otherHints,s=>(openBlock(),createElementBlock("div",{class:"form-check",key:s.id},[createBaseVNode("label",_hoisted_16,[withDirectives(createBaseVNode("input",{class:"form-check-input",type:"checkbox",value:s.id,"onUpdate:modelValue":t[1]||(t[1]=l=>e.selectedHints=l)},null,8,_hoisted_17),[[vModelCheckbox,e.selectedHints]]),createTextVNode(" "+toDisplayString(s.content)+" - "+toDisplayString(s.cost),1)])]))),128))])])])])]),_hoisted_18],32)])])])}const HintEditForm=_export_sfc(_sfc_main$2,[["render",_sfc_render$2]]),_sfc_main$1={components:{HintCreationForm,HintEditForm},props:{challenge_id:Number},data:function(){return{hints:[],editing_hint_id:null}},methods:{loadHints:async function(){let t=await(await CTFd$1.fetch(`/api/v1/challenges/${this.$props.challenge_id}/hints`,{method:"GET",credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"}})).json();return this.hints=t.data,t.success},addHint:function(){let e=this.$refs.HintCreationForm.$el;$(e).modal()},editHint:function(e){this.editing_hint_id=e;let t=this.$refs.HintEditForm.$el;$(t).modal()},refreshHints:function(e){this.loadHints().then(t=>{if(t){let n;switch(e){case"HintCreationForm":n=this.$refs.HintCreationForm.$el,console.log(n),$(n).modal("hide");break;case"HintEditForm":n=this.$refs.HintEditForm.$el,$(n).modal("hide");break}}else alert("An error occurred while updating this hint. Please try again.")})},deleteHint:function(e){ezQuery({title:"Delete Hint",body:"\xCAtes-vous certain de vouloir supprimer this hint?",success:()=>{CTFd$1.fetch(`/api/v1/hints/${e}`,{method:"DELETE"}).then(t=>t.json()).then(t=>{t.success&&this.loadHints()})}})}},created(){this.loadHints()}},_hoisted_1$1={class:"table table-striped"},_hoisted_2$1=createBaseVNode("thead",null,[createBaseVNode("tr",null,[createBaseVNode("td",{class:"text-center"},[createBaseVNode("b",null,"ID")]),createBaseVNode("td",{class:"text-center"},[createBaseVNode("b",null,"Hint")]),createBaseVNode("td",{class:"text-center"},[createBaseVNode("b",null,"Cost")]),createBaseVNode("td",{class:"text-center"},[createBaseVNode("b",null,"Settings")])])],-1),_hoisted_3$1={class:"text-center"},_hoisted_4$1={class:"text-break"},_hoisted_5$1={class:"text-center"},_hoisted_6$1={class:"text-center"},_hoisted_7=["onClick"],_hoisted_8=["onClick"],_hoisted_9={class:"col-md-12"};function _sfc_render$1(e,t,n,i,a,o){const s=resolveComponent("HintCreationForm"),l=resolveComponent("HintEditForm");return openBlock(),createElementBlock("div",null,[createBaseVNode("div",null,[createVNode(s,{ref:"HintCreationForm",challenge_id:n.challenge_id,hints:e.hints,onRefreshHints:o.refreshHints},null,8,["challenge_id","hints","onRefreshHints"])]),createBaseVNode("div",null,[createVNode(l,{ref:"HintEditForm",challenge_id:n.challenge_id,hint_id:e.editing_hint_id,hints:e.hints,onRefreshHints:o.refreshHints},null,8,["challenge_id","hint_id","hints","onRefreshHints"])]),createBaseVNode("table",_hoisted_1$1,[_hoisted_2$1,createBaseVNode("tbody",null,[(openBlock(!0),createElementBlock(Fragment,null,renderList(e.hints,d=>(openBlock(),createElementBlock("tr",{key:d.id},[createBaseVNode("td",_hoisted_3$1,toDisplayString(d.type),1),createBaseVNode("td",_hoisted_4$1,[createBaseVNode("pre",null,toDisplayString(d.content),1)]),createBaseVNode("td",_hoisted_5$1,toDisplayString(d.cost),1),createBaseVNode("td",_hoisted_6$1,[createBaseVNode("i",{role:"button",class:"btn-fa fas fa-edit",onClick:c=>o.editHint(d.id)},null,8,_hoisted_7),createBaseVNode("i",{role:"button",class:"btn-fa fas fa-times",onClick:c=>o.deleteHint(d.id)},null,8,_hoisted_8)])]))),128))])]),createBaseVNode("div",_hoisted_9,[createBaseVNode("button",{class:"btn btn-success float-right",onClick:t[0]||(t[0]=(...d)=>o.addHint&&o.addHint(...d))}," Create Hint ")])])}const HintsList=_export_sfc(_sfc_main$1,[["render",_sfc_render$1]]),_sfc_main={props:{challenge_id:Number},data:function(){return{challenge:null,challenges:[],selected_id:null}},computed:{updateAvailable:function(){return this.challenge?this.selected_id!=this.challenge.next_id:!1},otherChallenges:function(){return this.challenges.filter(e=>e.id!==this.$props.challenge_id)}},methods:{loadData:function(){CTFd$1.fetch(`/api/v1/challenges/${this.$props.challenge_id}`,{method:"GET",credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"}}).then(e=>e.json()).then(e=>{e.success&&(this.challenge=e.data,this.selected_id=e.data.next_id)})},loadChallenges:function(){CTFd$1.fetch("/api/v1/challenges?view=admin",{method:"GET",credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"}}).then(e=>e.json()).then(e=>{e.success&&(this.challenges=e.data)})},updateNext:function(){CTFd$1.fetch(`/api/v1/challenges/${this.$props.challenge_id}`,{method:"PATCH",credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"},body:JSON.stringify({next_id:this.selected_id!="null"?this.selected_id:null})}).then(e=>e.json()).then(e=>{e.success&&(this.loadData(),this.loadChallenges())})}},created(){this.loadData(),this.loadChallenges()}},_hoisted_1={class:"form-group"},_hoisted_2=createBaseVNode("label",null,[createTextVNode(" Next Challenge "),createBaseVNode("br"),createBaseVNode("small",{class:"text-muted"},"Challenge to recommend after solving this challenge")],-1),_hoisted_3=createBaseVNode("option",{value:"null"},"--",-1),_hoisted_4=["value"],_hoisted_5={class:"form-group"},_hoisted_6=["disabled"];function _sfc_render(e,t,n,i,a,o){return openBlock(),createElementBlock("div",null,[createBaseVNode("form",{onSubmit:t[1]||(t[1]=withModifiers((...s)=>o.updateNext&&o.updateNext(...s),["prevent"]))},[createBaseVNode("div",_hoisted_1,[_hoisted_2,withDirectives(createBaseVNode("select",{class:"form-control custom-select","onUpdate:modelValue":t[0]||(t[0]=s=>e.selected_id=s)},[_hoisted_3,(openBlock(!0),createElementBlock(Fragment,null,renderList(o.otherChallenges,s=>(openBlock(),createElementBlock("option",{value:s.id,key:s.id},toDisplayString(s.name),9,_hoisted_4))),128))],512),[[vModelSelect,e.selected_id]])]),createBaseVNode("div",_hoisted_5,[createBaseVNode("button",{class:"btn btn-success float-right",disabled:!o.updateAvailable}," Save ",8,_hoisted_6)])],32)])}const NextChallenge=_export_sfc(_sfc_main,[["render",_sfc_render]]);function loadChalTemplate(e){CTFd$1._internal.challenge={},$$1.getScript(CTFd$1.config.urlRoot+e.scripts.view,function(){let t=e.create;$$1("#create-chal-entry-div").html(t),bindMarkdownEditors(),$$1.getScript(CTFd$1.config.urlRoot+e.scripts.create,function(){$$1("#create-chal-entry-div form").submit(function(n){n.preventDefault();const i=$$1("#create-chal-entry-div form").serializeJSON();CTFd$1.fetch("/api/v1/challenges",{method:"POST",credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"},body:JSON.stringify(i)}).then(function(a){return a.json()}).then(function(a){if(a.success)$$1("#challenge-create-options #challenge_id").val(a.data.id),$$1("#challenge-create-options").modal();else{let o="";for(const s in a.errors)o+=a.errors[s].join(` +import{_ as _export_sfc,$ as $$1,C as CTFd$1,n as nunjucks,o as openBlock,c as createElementBlock,a as createBaseVNode,F as Fragment,r as renderList,t as toDisplayString,w as withModifiers,b as createCommentVNode,d as createStaticVNode,e as resolveComponent,f as createVNode,g as withCtx,T as TransitionGroup,h as withDirectives,v as vModelSelect,i as vModelCheckbox,j as createTextVNode,p as pushScopeId,k as popScopeId,l as vModelText,m as withKeys,q as normalizeClass,s as helpers,u as ezQuery,x as vShow,y as bindMarkdownEditor,z as htmlEntities,V as Vue$1,A as bindMarkdownEditors,B as ezAlert,D as ezToast}from"./main.71d0edc5.js";import"../tab.facb6ef1.js";import{C as CommentBox}from"../CommentBox.f5ce8d13.js";const _sfc_main$b={name:"FlagCreationForm",props:{challenge_id:Number},data:function(){return{types:{},selectedType:null,createForm:""}},methods:{selectType:function(event){let flagType=event.target.value;if(this.types[flagType]===void 0){this.selectedType=null,this.createForm="";return}let createFormURL=this.types[flagType].templates.create;$$1.get(CTFd$1.config.urlRoot+createFormURL,template_data=>{const template=nunjucks.compile(template_data);this.selectedType=flagType,this.createForm=template.render(),this.createForm.includes("<script")&&setTimeout(()=>{$$1("<div>"+this.createForm+"</div>").find("script").each(function(){eval($$1(this).html())})},100)})},loadTypes:function(){CTFd$1.fetch("/api/v1/flags/types",{method:"GET"}).then(e=>e.json()).then(e=>{this.types=e.data})},submitFlag:function(e){let n=$$1(e.target).serializeJSON(!0);n.challenge=this.$props.challenge_id,CTFd$1.fetch("/api/v1/flags",{method:"POST",credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"},body:JSON.stringify(n)}).then(i=>i.json()).then(i=>{this.$emit("refreshFlags",this.$options.name)})}},created(){this.loadTypes()}},_hoisted_1$b={id:"flag-create-modal",class:"modal fade",tabindex:"-1"},_hoisted_2$b={class:"modal-dialog modal-lg"},_hoisted_3$b={class:"modal-content"},_hoisted_4$b=createStaticVNode('<div class="modal-header text-center"><div class="container"><div class="row"><div class="col-md-12"><h3>Create Answer</h3></div></div></div><button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">\xD7</span></button></div>',1),_hoisted_5$b={class:"modal-body"},_hoisted_6$a={class:"create-keys-select-div"},_hoisted_7$8=createBaseVNode("label",{for:"create-keys-select",class:"control-label"}," Choose Answer Type ",-1),_hoisted_8$8=createBaseVNode("option",null,"--",-1),_hoisted_9$8=["value"],_hoisted_10$5=createBaseVNode("br",null,null,-1),_hoisted_11$6=["innerHTML"],_hoisted_12$5={key:0,class:"btn btn-secondary float-right",type:"submit"};function _sfc_render$b(e,t,n,i,a,o){return openBlock(),createElementBlock("div",_hoisted_1$b,[createBaseVNode("div",_hoisted_2$b,[createBaseVNode("div",_hoisted_3$b,[_hoisted_4$b,createBaseVNode("div",_hoisted_5$b,[createBaseVNode("div",_hoisted_6$a,[_hoisted_7$8,createBaseVNode("select",{class:"form-control custom-select",onChange:t[0]||(t[0]=s=>o.selectType(s))},[_hoisted_8$8,(openBlock(!0),createElementBlock(Fragment,null,renderList(Object.keys(e.types),s=>(openBlock(),createElementBlock("option",{value:s,key:s},toDisplayString(s),9,_hoisted_9$8))),128))],32)]),_hoisted_10$5,createBaseVNode("form",{onSubmit:t[1]||(t[1]=withModifiers((...s)=>o.submitFlag&&o.submitFlag(...s),["prevent"]))},[createBaseVNode("div",{id:"create-flag-form",innerHTML:e.createForm},null,8,_hoisted_11$6),e.createForm?(openBlock(),createElementBlock("button",_hoisted_12$5," Create Answer ")):createCommentVNode("",!0)],32)])])])])}const FlagCreationForm=_export_sfc(_sfc_main$b,[["render",_sfc_render$b]]),_sfc_main$a={name:"FlagEditForm",props:{flag_id:Number},data:function(){return{flag:{},editForm:""}},watch:{flag_id:{immediate:!0,handler(e,t){e!==null&&this.loadFlag()}}},methods:{loadFlag:function(){CTFd$1.fetch(`/api/v1/flags/${this.$props.flag_id}`,{method:"GET"}).then(e=>e.json()).then(response=>{this.flag=response.data;let editFormURL=this.flag.templates.update;$$1.get(CTFd$1.config.urlRoot+editFormURL,template_data=>{const template=nunjucks.compile(template_data);this.editForm=template.render(this.flag),this.editForm.includes("<script")&&setTimeout(()=>{$$1("<div>"+this.editForm+"</div>").find("script").each(function(){eval($$1(this).html())})},100)})})},updateFlag:function(e){let n=$$1(e.target).serializeJSON(!0);CTFd$1.fetch(`/api/v1/flags/${this.$props.flag_id}`,{method:"PATCH",credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"},body:JSON.stringify(n)}).then(i=>i.json()).then(i=>{this.$emit("refreshFlags",this.$options.name)})}},mounted(){this.flag_id&&this.loadFlag()},created(){this.flag_id&&this.loadFlag()}},_hoisted_1$a={id:"flag-edit-modal",class:"modal fade",tabindex:"-1"},_hoisted_2$a={class:"modal-dialog modal-lg"},_hoisted_3$a={class:"modal-content"},_hoisted_4$a=createStaticVNode('<div class="modal-header text-center"><div class="container"><div class="row"><div class="col-md-12"><h3 class="text-center">Edit Flag</h3></div></div></div><button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">\xD7</span></button></div>',1),_hoisted_5$a={class:"modal-body"},_hoisted_6$9=["innerHTML"];function _sfc_render$a(e,t,n,i,a,o){return openBlock(),createElementBlock("div",_hoisted_1$a,[createBaseVNode("div",_hoisted_2$a,[createBaseVNode("div",_hoisted_3$a,[_hoisted_4$a,createBaseVNode("div",_hoisted_5$a,[createBaseVNode("form",{method:"POST",innerHTML:e.editForm,onSubmit:t[0]||(t[0]=withModifiers((...s)=>o.updateFlag&&o.updateFlag(...s),["prevent"]))},null,40,_hoisted_6$9)])])])])}const FlagEditForm=_export_sfc(_sfc_main$a,[["render",_sfc_render$a]]),_sfc_main$9={components:{FlagCreationForm,FlagEditForm},props:{challenge_id:Number},data:function(){return{flags:[],editing_flag_id:null}},methods:{loadFlags:function(){CTFd$1.fetch(`/api/v1/challenges/${this.$props.challenge_id}/flags`,{method:"GET",credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"}}).then(e=>e.json()).then(e=>{e.success&&(this.flags=e.data)})},refreshFlags(e){this.loadFlags();let t;switch(e){case"FlagEditForm":t=this.$refs.FlagEditForm.$el,$$1(t).modal("hide");break;case"FlagCreationForm":t=this.$refs.FlagCreationForm.$el,$$1(t).modal("hide");break}},addFlag:function(){let e=this.$refs.FlagCreationForm.$el;$$1(e).modal()},editFlag:function(e){this.editing_flag_id=e;let t=this.$refs.FlagEditForm.$el;$$1(t).modal()},deleteFlag:function(e){confirm("Are you sure you'd like to delete this flag?")&&CTFd$1.fetch(`/api/v1/flags/${e}`,{method:"DELETE"}).then(t=>t.json()).then(t=>{t.success&&this.loadFlags()})}},created(){this.loadFlags()}},_hoisted_1$9={id:"flagsboard",class:"table table-striped"},_hoisted_2$9=createBaseVNode("thead",null,[createBaseVNode("tr",null,[createBaseVNode("td",{class:"text-center"},[createBaseVNode("b",null,"Type")]),createBaseVNode("td",{class:"text-center"},[createBaseVNode("b",null,"Answer")]),createBaseVNode("td",{class:"text-center"},[createBaseVNode("b",null,"Settings")])])],-1),_hoisted_3$9=["name"],_hoisted_4$9={class:"text-center"},_hoisted_5$9={class:"text-break"},_hoisted_6$8={class:"flag-content"},_hoisted_7$7={class:"text-center"},_hoisted_8$7=["flag-id","flag-type","onClick"],_hoisted_9$7=["flag-id","onClick"],_hoisted_10$4=createBaseVNode("td",{class:"text-center"},null,-1),_hoisted_11$5=createBaseVNode("td",{class:"text-break"},null,-1),_hoisted_12$4={class:"text-center"};function _sfc_render$9(e,t,n,i,a,o){const s=resolveComponent("FlagCreationForm"),l=resolveComponent("FlagEditForm");return openBlock(),createElementBlock("div",null,[createBaseVNode("div",null,[createVNode(s,{ref:"FlagCreationForm",challenge_id:n.challenge_id,onRefreshFlags:o.refreshFlags},null,8,["challenge_id","onRefreshFlags"])]),createBaseVNode("div",null,[createVNode(l,{ref:"FlagEditForm",flag_id:e.editing_flag_id,onRefreshFlags:o.refreshFlags},null,8,["flag_id","onRefreshFlags"])]),createBaseVNode("table",_hoisted_1$9,[_hoisted_2$9,createBaseVNode("tbody",null,[(openBlock(!0),createElementBlock(Fragment,null,renderList(e.flags,d=>(openBlock(),createElementBlock("tr",{name:d.id,key:d.id},[createBaseVNode("td",_hoisted_4$9,toDisplayString(d.type),1),createBaseVNode("td",_hoisted_5$9,[createBaseVNode("pre",_hoisted_6$8,toDisplayString(d.content),1)]),createBaseVNode("td",_hoisted_7$7,[createBaseVNode("i",{role:"button",class:"btn-fa fas fa-edit edit-flag","flag-id":d.id,"flag-type":d.type,onClick:c=>o.editFlag(d.id)},null,8,_hoisted_8$7),createBaseVNode("i",{role:"button",class:"btn-fa fas fa-times delete-flag","flag-id":d.id,onClick:c=>o.deleteFlag(d.id)},null,8,_hoisted_9$7)])],8,_hoisted_3$9))),128)),createBaseVNode("tr",null,[_hoisted_10$4,_hoisted_11$5,createBaseVNode("td",_hoisted_12$4,[createBaseVNode("i",{id:"flag-add-button",class:"btn-fa fas fa-plus add-flag",onClick:t[0]||(t[0]=d=>o.addFlag())})])])])])])}const FlagList=_export_sfc(_sfc_main$9,[["render",_sfc_render$9]]),Requirements_vue_vue_type_style_index_0_scoped_3c612631_lang="",_sfc_main$8={props:{challenge_id:Number},data:function(){return{challenges:[],requirements:{},selectedRequirements:[],selectedAnonymize:!1}},computed:{newRequirements:function(){let e=this.requirements.prerequisites||[],t=this.requirements.anonymize||!1,n=JSON.stringify(e.sort())!==JSON.stringify(this.selectedRequirements.sort()),i=t!==this.selectedAnonymize;return n||i},requiredChallenges:function(){const e=this.requirements.prerequisites||[];return this.challenges.filter(t=>t.id!==this.$props.challenge_id&&e.includes(t.id))},otherChallenges:function(){const e=this.requirements.prerequisites||[];return this.challenges.filter(t=>t.id!==this.$props.challenge_id&&!e.includes(t.id))}},methods:{loadChallenges:function(){CTFd$1.fetch("/api/v1/challenges?view=admin",{method:"GET",credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"}}).then(e=>e.json()).then(e=>{e.success&&(this.challenges=e.data)})},getChallengeNameById:function(e){let t=this.challenges.find(n=>n.id===e);return t?t.name:""},loadRequirements:function(){CTFd$1.fetch(`/api/v1/challenges/${this.$props.challenge_id}/requirements`,{method:"GET",credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"}}).then(e=>e.json()).then(e=>{e.success&&(this.requirements=e.data||{},this.selectedRequirements=this.requirements.prerequisites||[],this.selectedAnonymize=this.requirements.anonymize||!1)})},updateRequirements:function(){const t={requirements:{prerequisites:this.selectedRequirements}};this.selectedAnonymize&&(t.requirements.anonymize=!0),CTFd$1.fetch(`/api/v1/challenges/${this.$props.challenge_id}`,{method:"PATCH",credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"},body:JSON.stringify(t)}).then(n=>n.json()).then(n=>{n.success&&this.loadRequirements()})}},created(){this.loadChallenges(),this.loadRequirements()}},_withScopeId=e=>(pushScopeId("data-v-3c612631"),e=e(),popScopeId(),e),_hoisted_1$8={class:"form-group scrollbox"},_hoisted_2$8={class:"form-check-label cursor-pointer"},_hoisted_3$8=["value"],_hoisted_4$8={class:"form-check-label cursor-pointer"},_hoisted_5$8=["value"],_hoisted_6$7={class:"form-group"},_hoisted_7$6=_withScopeId(()=>createBaseVNode("label",null,[createBaseVNode("b",null,"Behavior if not unlocked")],-1)),_hoisted_8$6=_withScopeId(()=>createBaseVNode("option",{value:!1},"Cach\xE9",-1)),_hoisted_9$6=_withScopeId(()=>createBaseVNode("option",{value:!0},"Anonymized",-1)),_hoisted_10$3=[_hoisted_8$6,_hoisted_9$6],_hoisted_11$4={class:"form-group"},_hoisted_12$3=["disabled"];function _sfc_render$8(e,t,n,i,a,o){return openBlock(),createElementBlock("div",null,[createBaseVNode("form",{onSubmit:t[3]||(t[3]=withModifiers((...s)=>o.updateRequirements&&o.updateRequirements(...s),["prevent"]))},[createBaseVNode("div",_hoisted_1$8,[createVNode(TransitionGroup,{name:"flip-list"},{default:withCtx(()=>[(openBlock(!0),createElementBlock(Fragment,null,renderList(o.requiredChallenges,s=>(openBlock(),createElementBlock("div",{class:"form-check",key:s.id},[createBaseVNode("label",_hoisted_2$8,[withDirectives(createBaseVNode("input",{class:"form-check-input",type:"checkbox",value:s.id,"onUpdate:modelValue":t[0]||(t[0]=l=>e.selectedRequirements=l)},null,8,_hoisted_3$8),[[vModelCheckbox,e.selectedRequirements]]),createTextVNode(" "+toDisplayString(s.name),1)])]))),128)),(openBlock(!0),createElementBlock(Fragment,null,renderList(o.otherChallenges,s=>(openBlock(),createElementBlock("div",{class:"form-check",key:s.id},[createBaseVNode("label",_hoisted_4$8,[withDirectives(createBaseVNode("input",{class:"form-check-input",type:"checkbox",value:s.id,"onUpdate:modelValue":t[1]||(t[1]=l=>e.selectedRequirements=l)},null,8,_hoisted_5$8),[[vModelCheckbox,e.selectedRequirements]]),createTextVNode(" "+toDisplayString(s.name),1)])]))),128))]),_:1})]),createBaseVNode("div",_hoisted_6$7,[_hoisted_7$6,withDirectives(createBaseVNode("select",{class:"form-control custom-select",name:"anonymize","onUpdate:modelValue":t[2]||(t[2]=s=>e.selectedAnonymize=s)},_hoisted_10$3,512),[[vModelSelect,e.selectedAnonymize]])]),createBaseVNode("div",_hoisted_11$4,[createBaseVNode("button",{class:"btn btn-success float-right",disabled:!o.newRequirements}," Save ",8,_hoisted_12$3)])],32)])}const Requirements=_export_sfc(_sfc_main$8,[["render",_sfc_render$8],["__scopeId","data-v-3c612631"]]),_sfc_main$7={props:{challenge_id:Number},data:function(){return{topics:[],topicValue:"",searchedTopic:"",topicResults:[],selectedResultIdx:0,awaitingSearch:!1}},methods:{loadTopics:function(){CTFd$1.fetch(`/api/v1/challenges/${this.$props.challenge_id}/topics`,{method:"GET",credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"}}).then(e=>e.json()).then(e=>{e.success&&(this.topics=e.data)})},searchTopics:function(){if(this.selectedResultIdx=0,this.topicValue==""){this.topicResults=[];return}CTFd$1.fetch(`/api/v1/topics?field=value&q=${this.topicValue}`,{method:"GET",credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"}}).then(e=>e.json()).then(e=>{e.success&&(this.topicResults=e.data.slice(0,10))})},addTopic:function(){let e;if(this.selectedResultIdx===0)e=this.topicValue;else{let n=this.selectedResultIdx-1;e=this.topicResults[n].value}const t={value:e,challenge:this.$props.challenge_id,type:"challenge"};CTFd$1.fetch("/api/v1/topics",{method:"POST",body:JSON.stringify(t)}).then(n=>n.json()).then(n=>{n.success&&(this.topicValue="",this.loadTopics())})},deleteTopic:function(e){CTFd$1.fetch(`/api/v1/topics?type=challenge&target_id=${e}`,{method:"DELETE"}).then(t=>t.json()).then(t=>{t.success&&this.loadTopics()})},moveCursor:function(e){switch(e){case"up":this.selectedResultIdx&&(this.selectedResultIdx-=1);break;case"down":this.selectedResultIdx<this.topicResults.length&&(this.selectedResultIdx+=1);break}},selectTopic:function(e){e===void 0&&(e=this.selectedResultIdx);let t=this.topicResults[e];this.topicValue=t.value}},watch:{topicValue:function(e){this.awaitingSearch===!1&&setTimeout(()=>{this.searchTopics(),this.awaitingSearch=!1},500),this.awaitingSearch=!0}},created(){this.loadTopics()}},_hoisted_1$7={class:"col-md-12"},_hoisted_2$7={id:"challenge-topics",class:"my-3"},_hoisted_3$7={class:"mr-1"},_hoisted_4$7=["onClick"],_hoisted_5$7={class:"form-group"},_hoisted_6$6=createBaseVNode("label",null,[createTextVNode(" Topic "),createBaseVNode("br"),createBaseVNode("small",{class:"text-muted"},"Type topic and press Enter")],-1),_hoisted_7$5={class:"form-group"},_hoisted_8$5={class:"list-group"},_hoisted_9$5=["onClick"];function _sfc_render$7(e,t,n,i,a,o){return openBlock(),createElementBlock("div",_hoisted_1$7,[createBaseVNode("div",_hoisted_2$7,[(openBlock(!0),createElementBlock(Fragment,null,renderList(e.topics,s=>(openBlock(),createElementBlock("h5",{class:"challenge-tag",key:s.id},[createBaseVNode("span",_hoisted_3$7,toDisplayString(s.value),1),createBaseVNode("a",{class:"btn-fa delete-tag",onClick:l=>o.deleteTopic(s.id)}," \xD7",8,_hoisted_4$7)]))),128))]),createBaseVNode("div",_hoisted_5$7,[_hoisted_6$6,withDirectives(createBaseVNode("input",{id:"tags-add-input",maxlength:"255",type:"text",class:"form-control","onUpdate:modelValue":t[0]||(t[0]=s=>e.topicValue=s),onKeyup:[t[1]||(t[1]=withKeys(s=>o.moveCursor("down"),["down"])),t[2]||(t[2]=withKeys(s=>o.moveCursor("up"),["up"])),t[3]||(t[3]=withKeys(s=>o.addTopic(),["enter"]))]},null,544),[[vModelText,e.topicValue]])]),createBaseVNode("div",_hoisted_7$5,[createBaseVNode("ul",_hoisted_8$5,[(openBlock(!0),createElementBlock(Fragment,null,renderList(e.topicResults,(s,l)=>(openBlock(),createElementBlock("li",{class:normalizeClass({"list-group-item":!0,active:l+1===e.selectedResultIdx}),key:s.id,onClick:d=>o.selectTopic(l)},toDisplayString(s.value),11,_hoisted_9$5))),128))])])])}const TopicsList=_export_sfc(_sfc_main$7,[["render",_sfc_render$7]]),_sfc_main$6={props:{challenge_id:Number},data:function(){return{tags:[],tagValue:""}},methods:{loadTags:function(){CTFd$1.fetch(`/api/v1/challenges/${this.$props.challenge_id}/tags`,{method:"GET",credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"}}).then(e=>e.json()).then(e=>{e.success&&(this.tags=e.data)})},addTag:function(){if(this.tagValue){const e={value:this.tagValue,challenge:this.$props.challenge_id};CTFd$1.api.post_tag_list({},e).then(t=>{t.success&&(this.tagValue="",this.loadTags())})}},deleteTag:function(e){CTFd$1.api.delete_tag({tagId:e}).then(t=>{t.success&&this.loadTags()})}},created(){this.loadTags()}},_hoisted_1$6={class:"col-md-12"},_hoisted_2$6={id:"challenge-tags",class:"my-3"},_hoisted_3$6=["onClick"],_hoisted_4$6={class:"form-group"},_hoisted_5$6=createBaseVNode("label",null,[createTextVNode("Tag "),createBaseVNode("br"),createBaseVNode("small",{class:"text-muted"},"Type tag and press Enter")],-1);function _sfc_render$6(e,t,n,i,a,o){return openBlock(),createElementBlock("div",_hoisted_1$6,[createBaseVNode("div",_hoisted_2$6,[(openBlock(!0),createElementBlock(Fragment,null,renderList(e.tags,s=>(openBlock(),createElementBlock("span",{class:"badge badge-primary mx-1 challenge-tag",key:s.id},[createBaseVNode("span",null,toDisplayString(s.value),1),createBaseVNode("a",{class:"btn-fa delete-tag",onClick:l=>o.deleteTag(s.id)}," \xD7",8,_hoisted_3$6)]))),128))]),createBaseVNode("div",_hoisted_4$6,[_hoisted_5$6,withDirectives(createBaseVNode("input",{id:"tags-add-input",maxlength:"80",type:"text",class:"form-control","onUpdate:modelValue":t[0]||(t[0]=s=>e.tagValue=s),onKeyup:t[1]||(t[1]=withKeys(s=>o.addTag(),["enter"]))},null,544),[[vModelText,e.tagValue]])])])}const TagsList=_export_sfc(_sfc_main$6,[["render",_sfc_render$6]]),_sfc_main$5={props:{challenge_id:Number},data:function(){return{files:[],urlRoot:CTFd$1.config.urlRoot}},methods:{loadFiles:function(){CTFd$1.fetch(`/api/v1/challenges/${this.$props.challenge_id}/files`,{method:"GET"}).then(e=>e.json()).then(e=>{e.success&&(this.files=e.data)})},addFiles:function(){let e={challenge:this.$props.challenge_id,type:"challenge"},t=this.$refs.FileUploadForm;console.log("HELLODSDG"),helpers.files.upload(t,e,n=>{setTimeout(()=>{this.loadFiles()},700)},!0)},deleteFile:function(e){ezQuery({title:"Delete Files",body:"\xCAtes-vous certain de vouloir supprimer this file?",success:()=>{CTFd$1.fetch(`/api/v1/files/${e}`,{method:"DELETE"}).then(t=>t.json()).then(t=>{t.success&&this.loadFiles()})}})}},created(){this.loadFiles()}},_hoisted_1$5={style:{"max-width":"50vw"}},_hoisted_2$5={id:"filesboard",class:"table table-striped"},_hoisted_3$5=createBaseVNode("thead",null,[createBaseVNode("tr",null,[createBaseVNode("td",{class:"text-center"},[createBaseVNode("b",null,"File")]),createBaseVNode("td",{class:"text-center"},[createBaseVNode("b",null,"Settings")])])],-1),_hoisted_4$5={class:"text-center"},_hoisted_5$5=["href"],_hoisted_6$5={class:"text-center"},_hoisted_7$4=["onClick"],_hoisted_8$4={class:"col-md-12 mt-3"},_hoisted_9$4=createStaticVNode('<div class="form-group"><input class="form-control-file" id="file" multiple="" name="file" required="" type="file"><sub class="text-muted"> Attach multiple files using CTRL+Click or Cmd+Click. </sub></div><div class="form-group"><input class="btn btn-success float-right" id="_submit" name="_submit" type="submit" value="Upload"></div>',2),_hoisted_11$3=[_hoisted_9$4];function _sfc_render$5(e,t,n,i,a,o){return openBlock(),createElementBlock("div",_hoisted_1$5,[createBaseVNode("table",_hoisted_2$5,[_hoisted_3$5,createBaseVNode("tbody",null,[(openBlock(!0),createElementBlock(Fragment,null,renderList(e.files,s=>(openBlock(),createElementBlock("tr",{key:s.id},[createBaseVNode("td",_hoisted_4$5,[createBaseVNode("a",{href:`${e.urlRoot}/files/${s.location}`},toDisplayString(s.location.split("/").pop().length>30?s.location.split("/").pop().slice(0,30)+"...":s.location.split("/").pop()),9,_hoisted_5$5)]),createBaseVNode("td",_hoisted_6$5,[createBaseVNode("i",{role:"button",class:"btn-fa fas fa-times delete-file",onClick:l=>o.deleteFile(s.id)},null,8,_hoisted_7$4)])]))),128))])]),createBaseVNode("div",_hoisted_8$4,[createBaseVNode("form",{method:"POST",ref:"FileUploadForm",onSubmit:t[0]||(t[0]=withModifiers((...s)=>o.addFiles&&o.addFiles(...s),["prevent"]))},_hoisted_11$3,544)])])}const ChallengeFilesList=_export_sfc(_sfc_main$5,[["render",_sfc_render$5]]),_sfc_main$4={props:{challengeId:Number,challengeName:String,CHALLENGE_THUMBSNAIL:String},data:function(){return{files:[],urlRoot:CTFd$1.config.urlRoot}},methods:{updateThumbsnailPath(e){CTFd$1.fetch(`/api/v1/challenges/${CHALLENGE_ID}/thumbsnail`,{method:"PATCH",headers:{"Content-Type":"application/json"},body:JSON.stringify({thumbsnail:e})}).then(t=>t.json()).then(t=>{t.success?console.log("Thumbsnail path updated successfully."):console.error("Failed to update thumbsnail path:",t.message)})}},mounted(){document.getElementById("btn-file-input").style.display="block",document.getElementById("btn-file-input").addEventListener("click",()=>{document.getElementById("thumbsnail-get-path").click()}),document.getElementById("thumbsnail-get-path").addEventListener("change",e=>{const t=e.target.files[0];let n=document.getElementById("thumbsnail-upload-form");const i=new FormData(n);if(i.append("file",t),helpers.files.upload(i,n,a=>{const o=a.data[0],s=CTFd$1.config.urlRoot+"/files/"+o.location;document.getElementById("thumbsnail-path").value=s,console.log("Thumbnail uploaded successfully:",s);const l=document.getElementById("image-preview");l.src=s,l.style.display="block",this.updateThumbsnailPath(s)}),t){const a=new FileReader;a.onload=function(o){const s=document.getElementById("image-preview");s.src=o.target.result,s.style.display="block"},a.readAsDataURL(t)}})}},_hoisted_1$4={id:"Thumbsnailboard",class:"table table-striped"},_hoisted_2$4=createBaseVNode("thead",null,[createBaseVNode("tr",null,[createBaseVNode("td",{class:"text-center"},[createBaseVNode("b",null,"Miniature")]),createBaseVNode("td",{class:"text-center"},[createBaseVNode("b",null,"Settings")])])],-1),_hoisted_3$4={class:"text-center"},_hoisted_4$4=["href"],_hoisted_5$4={class:"text-center"},_hoisted_6$4=["onClick"],_hoisted_7$3={class:"col-md-12 mt-3"},_hoisted_8$3={id:"thumbsnail-upload-form",class:"form-upload",method:"POST",enctype:"multipart/form-data"},_hoisted_9$3=createBaseVNode("button",{id:"btn-file-input",class:"btn btn-secondary",type:"button"},"Select File",-1),_hoisted_10$2=["src"],_hoisted_11$2=createBaseVNode("input",{class:"form-control-file",id:"thumbsnail-get-path",name:"file",type:"file",accept:".png",style:{display:"none"}},null,-1),_hoisted_12$2=createBaseVNode("input",{type:"hidden",id:"thumbsnail-path",name:"thumbsnail"},null,-1);function _sfc_render$4(e,t,n,i,a,o){return openBlock(),createElementBlock("div",null,[createBaseVNode("table",_hoisted_1$4,[_hoisted_2$4,createBaseVNode("tbody",null,[(openBlock(!0),createElementBlock(Fragment,null,renderList(e.files,s=>(openBlock(),createElementBlock("tr",{key:s.id},[createBaseVNode("td",_hoisted_3$4,[createBaseVNode("a",{href:`${e.urlRoot}/files/${s.location}`},toDisplayString(s.location.split("/").pop()),9,_hoisted_4$4)]),createBaseVNode("td",_hoisted_5$4,[createBaseVNode("i",{role:"button",class:"btn-fa fas fa-times delete-file",onClick:l=>e.deleteFile(s.id)},null,8,_hoisted_6$4)])]))),128))])]),createBaseVNode("div",_hoisted_7$3,[createBaseVNode("form",_hoisted_8$3,[_hoisted_9$3,withDirectives(createBaseVNode("img",{id:"image-preview",src:n.CHALLENGE_THUMBSNAIL,style:{width:"100px",height:"100px","margin-top":"10px"}},null,8,_hoisted_10$2),[[vShow,n.CHALLENGE_THUMBSNAIL]]),_hoisted_11$2,_hoisted_12$2])])])}const ChallengeThumbsnail=_export_sfc(_sfc_main$4,[["render",_sfc_render$4]]),_sfc_main$3={name:"HintCreationForm",props:{challenge_id:Number,hints:Array},data:function(){return{cost:0,selectedHints:[]}},methods:{getCost:function(){return this.cost||0},getContent:function(){return this.$refs.content.value},submitHint:function(){let e={challenge_id:this.$props.challenge_id,content:this.getContent(),cost:this.getCost(),requirements:{prerequisites:this.selectedHints}};CTFd.fetch("/api/v1/hints",{method:"POST",credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"},body:JSON.stringify(e)}).then(t=>t.json()).then(t=>{t.success&&this.$emit("refreshHints",this.$options.name)})}}},_hoisted_1$3={class:"modal fade",tabindex:"-1"},_hoisted_2$3={class:"modal-dialog"},_hoisted_3$3={class:"modal-content"},_hoisted_4$3=createStaticVNode('<div class="modal-header text-center"><div class="container"><div class="row"><div class="col-md-12"><h3>Hint</h3></div></div></div><button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">\xD7</span></button></div>',1),_hoisted_5$3={class:"modal-body"},_hoisted_6$3={class:"container"},_hoisted_7$2={class:"row"},_hoisted_8$2={class:"col-md-12"},_hoisted_9$2={class:"form-group"},_hoisted_10$1=createBaseVNode("label",null,[createTextVNode(" Hint"),createBaseVNode("br"),createBaseVNode("small",null,"Markdown & HTML are supported")],-1),_hoisted_11$1={type:"text",class:"form-control markdown",name:"content",rows:"7",ref:"content"},_hoisted_12$1={class:"form-group"},_hoisted_13$1=createBaseVNode("label",null,[createTextVNode(" Cost"),createBaseVNode("br"),createBaseVNode("small",null,"How many points it costs to see your hint.")],-1),_hoisted_14$1={class:"form-group"},_hoisted_15$1=createBaseVNode("label",null,[createTextVNode(" Requirements"),createBaseVNode("br"),createBaseVNode("small",null,"Hints that must be unlocked before unlocking this hint")],-1),_hoisted_16$1={class:"form-check-label cursor-pointer"},_hoisted_17$1=["value"],_hoisted_18$1=createBaseVNode("input",{type:"hidden",id:"hint-id-for-hint",name:"id"},null,-1),_hoisted_19=createStaticVNode('<div class="modal-footer"><div class="container"><div class="row"><div class="col-md-12"><button class="btn btn-primary float-right">Submit</button></div></div></div></div>',1);function _sfc_render$3(e,t,n,i,a,o){return openBlock(),createElementBlock("div",_hoisted_1$3,[createBaseVNode("div",_hoisted_2$3,[createBaseVNode("div",_hoisted_3$3,[_hoisted_4$3,createBaseVNode("form",{method:"POST",onSubmit:t[2]||(t[2]=withModifiers((...s)=>o.submitHint&&o.submitHint(...s),["prevent"]))},[createBaseVNode("div",_hoisted_5$3,[createBaseVNode("div",_hoisted_6$3,[createBaseVNode("div",_hoisted_7$2,[createBaseVNode("div",_hoisted_8$2,[createBaseVNode("div",_hoisted_9$2,[_hoisted_10$1,createBaseVNode("textarea",_hoisted_11$1,null,512)]),createBaseVNode("div",_hoisted_12$1,[_hoisted_13$1,withDirectives(createBaseVNode("input",{type:"number",class:"form-control",name:"cost","onUpdate:modelValue":t[0]||(t[0]=s=>e.cost=s)},null,512),[[vModelText,e.cost,void 0,{lazy:!0}]])]),createBaseVNode("div",_hoisted_14$1,[_hoisted_15$1,(openBlock(!0),createElementBlock(Fragment,null,renderList(n.hints,s=>(openBlock(),createElementBlock("div",{class:"form-check",key:s.id},[createBaseVNode("label",_hoisted_16$1,[withDirectives(createBaseVNode("input",{class:"form-check-input",type:"checkbox",value:s.id,"onUpdate:modelValue":t[1]||(t[1]=l=>e.selectedHints=l)},null,8,_hoisted_17$1),[[vModelCheckbox,e.selectedHints]]),createTextVNode(" "+toDisplayString(s.cost)+" - "+toDisplayString(s.id),1)])]))),128))]),_hoisted_18$1])])])]),_hoisted_19],32)])])])}const HintCreationForm=_export_sfc(_sfc_main$3,[["render",_sfc_render$3]]),_sfc_main$2={name:"HintEditForm",props:{challenge_id:Number,hint_id:Number,hints:Array},data:function(){return{cost:0,content:null,selectedHints:[]}},computed:{otherHints:function(){return this.hints.filter(e=>e.id!==this.$props.hint_id)}},watch:{hint_id:{immediate:!0,handler(e,t){e!==null&&this.loadHint()}}},methods:{loadHint:function(){CTFd$1.fetch(`/api/v1/hints/${this.$props.hint_id}?preview=true`,{method:"GET",credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"}}).then(e=>e.json()).then(e=>{var t;if(e.success){let n=e.data;this.cost=n.cost,this.content=n.content,this.selectedHints=((t=n.requirements)==null?void 0:t.prerequisites)||[];let i=this.$refs.content;bindMarkdownEditor(i),setTimeout(()=>{i.mde.codemirror.getDoc().setValue(i.value),this._forceRefresh()},200)}})},_forceRefresh:function(){this.$refs.content.mde.codemirror.refresh()},getCost:function(){return this.cost||0},getContent:function(){return this._forceRefresh(),this.$refs.content.mde.codemirror.getDoc().getValue()},updateHint:function(){let e={challenge_id:this.$props.challenge_id,content:this.getContent(),cost:this.getCost(),requirements:{prerequisites:this.selectedHints}};CTFd$1.fetch(`/api/v1/hints/${this.$props.hint_id}`,{method:"PATCH",credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"},body:JSON.stringify(e)}).then(t=>t.json()).then(t=>{t.success&&this.$emit("refreshHints",this.$options.name)})}},mounted(){this.hint_id&&this.loadHint()},created(){this.hint_id&&this.loadHint()}},_hoisted_1$2={class:"modal fade",tabindex:"-1"},_hoisted_2$2={class:"modal-dialog"},_hoisted_3$2={class:"modal-content"},_hoisted_4$2=createStaticVNode('<div class="modal-header text-center"><div class="container"><div class="row"><div class="col-md-12"><h3>Hint</h3></div></div></div><button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">\xD7</span></button></div>',1),_hoisted_5$2={class:"modal-body"},_hoisted_6$2={class:"container"},_hoisted_7$1={class:"row"},_hoisted_8$1={class:"col-md-12"},_hoisted_9$1={class:"form-group"},_hoisted_10=createBaseVNode("label",null,[createTextVNode(" Hint"),createBaseVNode("br"),createBaseVNode("small",null,"Markdown & HTML are supported")],-1),_hoisted_11=["value"],_hoisted_12={class:"form-group"},_hoisted_13=createBaseVNode("label",null,[createTextVNode(" Cost"),createBaseVNode("br"),createBaseVNode("small",null,"How many points it costs to see your hint.")],-1),_hoisted_14={class:"form-group"},_hoisted_15=createBaseVNode("label",null,[createTextVNode(" Requirements"),createBaseVNode("br"),createBaseVNode("small",null,"Hints that must be unlocked before unlocking this hint")],-1),_hoisted_16={class:"form-check-label cursor-pointer"},_hoisted_17=["value"],_hoisted_18=createStaticVNode('<div class="modal-footer"><div class="container"><div class="row"><div class="col-md-12"><button class="btn btn-primary float-right">Submit</button></div></div></div></div>',1);function _sfc_render$2(e,t,n,i,a,o){return openBlock(),createElementBlock("div",_hoisted_1$2,[createBaseVNode("div",_hoisted_2$2,[createBaseVNode("div",_hoisted_3$2,[_hoisted_4$2,createBaseVNode("form",{method:"POST",onSubmit:t[2]||(t[2]=withModifiers((...s)=>o.updateHint&&o.updateHint(...s),["prevent"]))},[createBaseVNode("div",_hoisted_5$2,[createBaseVNode("div",_hoisted_6$2,[createBaseVNode("div",_hoisted_7$1,[createBaseVNode("div",_hoisted_8$1,[createBaseVNode("div",_hoisted_9$1,[_hoisted_10,createBaseVNode("textarea",{type:"text",class:"form-control",name:"content",rows:"7",value:this.content,ref:"content"},null,8,_hoisted_11)]),createBaseVNode("div",_hoisted_12,[_hoisted_13,withDirectives(createBaseVNode("input",{type:"number",class:"form-control",name:"cost","onUpdate:modelValue":t[0]||(t[0]=s=>e.cost=s)},null,512),[[vModelText,e.cost,void 0,{lazy:!0}]])]),createBaseVNode("div",_hoisted_14,[_hoisted_15,(openBlock(!0),createElementBlock(Fragment,null,renderList(o.otherHints,s=>(openBlock(),createElementBlock("div",{class:"form-check",key:s.id},[createBaseVNode("label",_hoisted_16,[withDirectives(createBaseVNode("input",{class:"form-check-input",type:"checkbox",value:s.id,"onUpdate:modelValue":t[1]||(t[1]=l=>e.selectedHints=l)},null,8,_hoisted_17),[[vModelCheckbox,e.selectedHints]]),createTextVNode(" "+toDisplayString(s.content)+" - "+toDisplayString(s.cost),1)])]))),128))])])])])]),_hoisted_18],32)])])])}const HintEditForm=_export_sfc(_sfc_main$2,[["render",_sfc_render$2]]),_sfc_main$1={components:{HintCreationForm,HintEditForm},props:{challenge_id:Number},data:function(){return{hints:[],editing_hint_id:null}},methods:{loadHints:async function(){let t=await(await CTFd$1.fetch(`/api/v1/challenges/${this.$props.challenge_id}/hints`,{method:"GET",credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"}})).json();return this.hints=t.data,t.success},addHint:function(){let e=this.$refs.HintCreationForm.$el;$(e).modal()},editHint:function(e){this.editing_hint_id=e;let t=this.$refs.HintEditForm.$el;$(t).modal()},refreshHints:function(e){this.loadHints().then(t=>{if(t){let n;switch(e){case"HintCreationForm":n=this.$refs.HintCreationForm.$el,console.log(n),$(n).modal("hide");break;case"HintEditForm":n=this.$refs.HintEditForm.$el,$(n).modal("hide");break}}else alert("An error occurred while updating this hint. Please try again.")})},deleteHint:function(e){ezQuery({title:"Delete Hint",body:"\xCAtes-vous certain de vouloir supprimer this hint?",success:()=>{CTFd$1.fetch(`/api/v1/hints/${e}`,{method:"DELETE"}).then(t=>t.json()).then(t=>{t.success&&this.loadHints()})}})}},created(){this.loadHints()}},_hoisted_1$1={class:"table table-striped"},_hoisted_2$1=createBaseVNode("thead",null,[createBaseVNode("tr",null,[createBaseVNode("td",{class:"text-center"},[createBaseVNode("b",null,"ID")]),createBaseVNode("td",{class:"text-center"},[createBaseVNode("b",null,"Hint")]),createBaseVNode("td",{class:"text-center"},[createBaseVNode("b",null,"Cost")]),createBaseVNode("td",{class:"text-center"},[createBaseVNode("b",null,"Settings")])])],-1),_hoisted_3$1={class:"text-center"},_hoisted_4$1={class:"text-break"},_hoisted_5$1={class:"text-center"},_hoisted_6$1={class:"text-center"},_hoisted_7=["onClick"],_hoisted_8=["onClick"],_hoisted_9={class:"col-md-12"};function _sfc_render$1(e,t,n,i,a,o){const s=resolveComponent("HintCreationForm"),l=resolveComponent("HintEditForm");return openBlock(),createElementBlock("div",null,[createBaseVNode("div",null,[createVNode(s,{ref:"HintCreationForm",challenge_id:n.challenge_id,hints:e.hints,onRefreshHints:o.refreshHints},null,8,["challenge_id","hints","onRefreshHints"])]),createBaseVNode("div",null,[createVNode(l,{ref:"HintEditForm",challenge_id:n.challenge_id,hint_id:e.editing_hint_id,hints:e.hints,onRefreshHints:o.refreshHints},null,8,["challenge_id","hint_id","hints","onRefreshHints"])]),createBaseVNode("table",_hoisted_1$1,[_hoisted_2$1,createBaseVNode("tbody",null,[(openBlock(!0),createElementBlock(Fragment,null,renderList(e.hints,d=>(openBlock(),createElementBlock("tr",{key:d.id},[createBaseVNode("td",_hoisted_3$1,toDisplayString(d.type),1),createBaseVNode("td",_hoisted_4$1,[createBaseVNode("pre",null,toDisplayString(d.content),1)]),createBaseVNode("td",_hoisted_5$1,toDisplayString(d.cost),1),createBaseVNode("td",_hoisted_6$1,[createBaseVNode("i",{role:"button",class:"btn-fa fas fa-edit",onClick:c=>o.editHint(d.id)},null,8,_hoisted_7),createBaseVNode("i",{role:"button",class:"btn-fa fas fa-times",onClick:c=>o.deleteHint(d.id)},null,8,_hoisted_8)])]))),128))])]),createBaseVNode("div",_hoisted_9,[createBaseVNode("button",{class:"btn btn-success float-right",onClick:t[0]||(t[0]=(...d)=>o.addHint&&o.addHint(...d))}," Create Hint ")])])}const HintsList=_export_sfc(_sfc_main$1,[["render",_sfc_render$1]]),_sfc_main={props:{challenge_id:Number},data:function(){return{challenge:null,challenges:[],selected_id:null}},computed:{updateAvailable:function(){return this.challenge?this.selected_id!=this.challenge.next_id:!1},otherChallenges:function(){return this.challenges.filter(e=>e.id!==this.$props.challenge_id)}},methods:{loadData:function(){CTFd$1.fetch(`/api/v1/challenges/${this.$props.challenge_id}`,{method:"GET",credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"}}).then(e=>e.json()).then(e=>{e.success&&(this.challenge=e.data,this.selected_id=e.data.next_id)})},loadChallenges:function(){CTFd$1.fetch("/api/v1/challenges?view=admin",{method:"GET",credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"}}).then(e=>e.json()).then(e=>{e.success&&(this.challenges=e.data)})},updateNext:function(){CTFd$1.fetch(`/api/v1/challenges/${this.$props.challenge_id}`,{method:"PATCH",credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"},body:JSON.stringify({next_id:this.selected_id!="null"?this.selected_id:null})}).then(e=>e.json()).then(e=>{e.success&&(this.loadData(),this.loadChallenges())})}},created(){this.loadData(),this.loadChallenges()}},_hoisted_1={class:"form-group"},_hoisted_2=createBaseVNode("label",null,[createTextVNode(" Next Challenge "),createBaseVNode("br"),createBaseVNode("small",{class:"text-muted"},"Challenge to recommend after solving this challenge")],-1),_hoisted_3=createBaseVNode("option",{value:"null"},"--",-1),_hoisted_4=["value"],_hoisted_5={class:"form-group"},_hoisted_6=["disabled"];function _sfc_render(e,t,n,i,a,o){return openBlock(),createElementBlock("div",null,[createBaseVNode("form",{onSubmit:t[1]||(t[1]=withModifiers((...s)=>o.updateNext&&o.updateNext(...s),["prevent"]))},[createBaseVNode("div",_hoisted_1,[_hoisted_2,withDirectives(createBaseVNode("select",{class:"form-control custom-select","onUpdate:modelValue":t[0]||(t[0]=s=>e.selected_id=s)},[_hoisted_3,(openBlock(!0),createElementBlock(Fragment,null,renderList(o.otherChallenges,s=>(openBlock(),createElementBlock("option",{value:s.id,key:s.id},toDisplayString(s.name),9,_hoisted_4))),128))],512),[[vModelSelect,e.selected_id]])]),createBaseVNode("div",_hoisted_5,[createBaseVNode("button",{class:"btn btn-success float-right",disabled:!o.updateAvailable}," Save ",8,_hoisted_6)])],32)])}const NextChallenge=_export_sfc(_sfc_main,[["render",_sfc_render]]);function loadChalTemplate(e){CTFd$1._internal.challenge={},$$1.getScript(CTFd$1.config.urlRoot+e.scripts.view,function(){let t=e.create;$$1("#create-chal-entry-div").html(t),bindMarkdownEditors(),$$1.getScript(CTFd$1.config.urlRoot+e.scripts.create,function(){$$1("#create-chal-entry-div form").submit(function(n){n.preventDefault();const i=$$1("#create-chal-entry-div form").serializeJSON();CTFd$1.fetch("/api/v1/challenges",{method:"POST",credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"},body:JSON.stringify(i)}).then(function(a){return a.json()}).then(function(a){if(a.success)$$1("#challenge-create-options #challenge_id").val(a.data.id),$$1("#challenge-create-options").modal();else{let o="";for(const s in a.errors)o+=a.errors[s].join(` `),o+=` `;ezAlert({title:"Erreur",body:o,button:"Ok"})}})})})})}function handleChallengeOptions(e){print("hit"),e.preventDefault();var t=$$1(e.target).serializeJSON(!0);let n={challenge_id:t.challenge_id,content:t.flag||"",type:t.flag_type,data:t.flag_data?t.flag_data:""},i=function(){setTimeout(function(){window.location=CTFd$1.config.urlRoot+"/admin/challenges#challenge-create-options-quick"},700)};Promise.all([new Promise(function(a,o){if(n.content.length==0){a();return}CTFd$1.fetch("/api/v1/flags",{method:"POST",credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"},body:JSON.stringify(n)}).then(function(s){a(s.json())})}),new Promise(function(a,o){let s=e.target,l={challenge:t.challenge_id,type:"challenge"};$$1(s.elements.file).val()&&helpers.files.upload(s,l),a()})]).then(a=>{i()})}$$1(()=>{if($$1(".preview-challenge").click(function(e){let t=`${CTFd$1.config.urlRoot}/admin/challenges/preview/${window.CHALLENGE_ID}`;$$1("#challenge-window").html(`<iframe src="${t}" height="100%" width="100%" frameBorder=0></iframe>`),$$1("#challenge-modal").modal()}),$$1(".comments-challenge").click(function(e){$$1("#challenge-comments-window").modal()}),$$1(".delete-challenge").click(function(e){ezQuery({title:"Delete Challenge",body:`\xCAtes-vous certain de vouloir supprimer <strong>${htmlEntities(window.CHALLENGE_NAME)}</strong>`,success:function(){CTFd$1.fetch("/api/v1/challenges/"+window.CHALLENGE_ID,{method:"DELETE"}).then(function(t){return t.json()}).then(function(t){t.success&&(window.location=CTFd$1.config.urlRoot+"/admin/challenges")})}})}),$$1("#challenge-update-container > form").submit(function(e){e.preventDefault();var t=$$1(e.target).serializeJSON(!0);console.log(t),CTFd$1.fetch("/api/v1/challenges/"+window.CHALLENGE_ID+"/flags",{method:"GET",credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"}}).then(function(n){return n.json()}).then(function(n){(function(){CTFd$1.fetch("/api/v1/challenges/"+window.CHALLENGE_ID,{method:"PATCH",credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"},body:JSON.stringify(t)}).then(function(a){return a.json()}).then(function(a){if(a.success){switch($$1(".challenge-state").text(a.data.state),a.data.state){case"visible":$$1(".challenge-state").removeClass("badge-danger").addClass("badge-success");break;case"hidden":$$1(".challenge-state").removeClass("badge-success").addClass("badge-danger");break}ezToast({title:"Succ\xE8s",body:"Votre d\xE9fi a \xE9t\xE9 mis \xE0 jour!"})}else{let o="";for(const s in a.errors)o+=a.errors[s].join(` `),o+=` diff --git a/CTFd/themes/admin/static/assets/pages/challenges.6f3449ed.js b/CTFd/themes/admin/static/assets/pages/challenges.a6549073.js similarity index 99% rename from CTFd/themes/admin/static/assets/pages/challenges.6f3449ed.js rename to CTFd/themes/admin/static/assets/pages/challenges.a6549073.js index 09f2fdc3cea7c70573122f38c220508b0c9cb6fe..cbac62cac2cc68a997815c52203e33504349b817 100644 --- a/CTFd/themes/admin/static/assets/pages/challenges.6f3449ed.js +++ b/CTFd/themes/admin/static/assets/pages/challenges.a6549073.js @@ -1,4 +1,4 @@ -import{s as E,C as m,$ as i,B as p,u as S}from"./main.9b987665.js";document.addEventListener("DOMContentLoaded",function(g){document.getElementById("btn-file-input").addEventListener("click",function(t){document.getElementById("thumbsnail-get-path").click()}),document.getElementById("thumbsnail-get-path").addEventListener("change",function(t){const e=t.target.files[0];let a=document.getElementById("thumbsnail-upload-form");const l=new FormData(a);if(l.append("file",e),E.files.upload(l,a,function(r){const f=r.data[0],c=m.config.urlRoot+"/files/"+f.location;document.getElementById("thumbsnail-path").value=c,console.log("Miniature t\xE9l\xE9charg\xE9e avec succ\xE8s:",c);const v=document.getElementById("image-preview");v.src=c,v.style.display="block"}),e){const r=new FileReader;r.onload=function(f){const c=document.getElementById("image-preview");c.src=f.target.result,c.style.display="block"},r.readAsDataURL(e)}});const o=Object.keys(document.categories),d=document.getElementById("categories-selector");o.forEach(t=>{const e=document.createElement("option");e.value=t,e.textContent=t,e.textContent!="D\xE9fi Flash"&&d.appendChild(e)});const s=document.createElement("option");s.value="other",s.textContent="Other (type below)",d.appendChild(s);const n=document.getElementById("categories-selector-input");d.value=="other"||o.length==0?(n.style.display="block",n.name="category"):(n.style.display="none",n.value="",n.name=""),d.addEventListener("change",function(){d.value=="other"||o.length==0?(n.style.display="block",n.name="category"):(n.style.display="none",n.value="",n.name="")});let u=0;document.querySelectorAll("td.id").forEach(function(t){const e=parseInt(t.textContent);!isNaN(e)&&e>u&&(u=e)});const h=u+1;document.getElementById("challenge_id_texte").textContent=h,document.getElementById("challenge_id").value=h;function D(){const t=i("#challenge-create-options-quick").serializeJSON();let e=document.getElementById("categories-selector"),a=document.getElementById("categories-selector-input"),l=document.getElementById("time-selector-input");e.hidden&&t.type!="flash"?(l.hidden=!0,a.hidden=!1,e.hidden=!1):!e.hidden&&t.type=="flash"&&(l.hidden=!1,a.hidden=!0,e.hidden=!0)}function b(t){p({title:"Choisir P\xE9riode",body:`<div class="mb-3" style="text-align: center;"> +import{s as E,C as m,$ as i,B as p,u as S}from"./main.71d0edc5.js";document.addEventListener("DOMContentLoaded",function(g){document.getElementById("btn-file-input").addEventListener("click",function(t){document.getElementById("thumbsnail-get-path").click()}),document.getElementById("thumbsnail-get-path").addEventListener("change",function(t){const e=t.target.files[0];let a=document.getElementById("thumbsnail-upload-form");const l=new FormData(a);if(l.append("file",e),E.files.upload(l,a,function(r){const f=r.data[0],c=m.config.urlRoot+"/files/"+f.location;document.getElementById("thumbsnail-path").value=c,console.log("Miniature t\xE9l\xE9charg\xE9e avec succ\xE8s:",c);const v=document.getElementById("image-preview");v.src=c,v.style.display="block"}),e){const r=new FileReader;r.onload=function(f){const c=document.getElementById("image-preview");c.src=f.target.result,c.style.display="block"},r.readAsDataURL(e)}});const o=Object.keys(document.categories),d=document.getElementById("categories-selector");o.forEach(t=>{const e=document.createElement("option");e.value=t,e.textContent=t,e.textContent!="D\xE9fi Flash"&&d.appendChild(e)});const s=document.createElement("option");s.value="other",s.textContent="Other (type below)",d.appendChild(s);const n=document.getElementById("categories-selector-input");d.value=="other"||o.length==0?(n.style.display="block",n.name="category"):(n.style.display="none",n.value="",n.name=""),d.addEventListener("change",function(){d.value=="other"||o.length==0?(n.style.display="block",n.name="category"):(n.style.display="none",n.value="",n.name="")});let u=0;document.querySelectorAll("td.id").forEach(function(t){const e=parseInt(t.textContent);!isNaN(e)&&e>u&&(u=e)});const h=u+1;document.getElementById("challenge_id_texte").textContent=h,document.getElementById("challenge_id").value=h;function D(){const t=i("#challenge-create-options-quick").serializeJSON();let e=document.getElementById("categories-selector"),a=document.getElementById("categories-selector-input"),l=document.getElementById("time-selector-input");e.hidden&&t.type!="flash"?(l.hidden=!0,a.hidden=!1,e.hidden=!1):!e.hidden&&t.type=="flash"&&(l.hidden=!1,a.hidden=!0,e.hidden=!0)}function b(t){p({title:"Choisir P\xE9riode",body:`<div class="mb-3" style="text-align: center;"> <label>D\xE9but</label> <div class="row" style="justify-content: space-around;"> diff --git a/CTFd/themes/admin/static/assets/pages/configs.106ed7c5.js b/CTFd/themes/admin/static/assets/pages/configs.1b411858.js similarity index 99% rename from CTFd/themes/admin/static/assets/pages/configs.106ed7c5.js rename to CTFd/themes/admin/static/assets/pages/configs.1b411858.js index c2daf04828f114d6cc2106073f800d1969589229..291f87e712d69c6239af67c91d59c5155501c5b1 100644 --- a/CTFd/themes/admin/static/assets/pages/configs.106ed7c5.js +++ b/CTFd/themes/admin/static/assets/pages/configs.1b411858.js @@ -1,4 +1,4 @@ -import{H as q,_ as G,C as p,D as K,o as $,c as P,a as i,h as M,v as W,l as j,i as F,j as U,e as Z,F as Q,r as X,f as ee,I as x,K as re,$ as t,V as J,B as O,s as R,u as Y,L as z}from"./main.9b987665.js";import"../tab.39c73246.js";import{c as L}from"../htmlmixed.abcfee66.js";var ae={exports:{}};(function(e,a){(function(r,s){e.exports=s()})(q,function(){var r="minute",s=/[+-]\d\d(?::?\d\d)?/g,l=/([+-]|\d\d)/g;return function(c,o,d){var u=o.prototype;d.utc=function(n){var A={date:n,utc:!0,args:arguments};return new o(A)},u.utc=function(n){var A=d(this.toDate(),{locale:this.$L,utc:!0});return n?A.add(this.utcOffset(),r):A},u.local=function(){return d(this.toDate(),{locale:this.$L,utc:!1})};var E=u.parse;u.parse=function(n){n.utc&&(this.$u=!0),this.$utils().u(n.$offset)||(this.$offset=n.$offset),E.call(this,n)};var S=u.init;u.init=function(){if(this.$u){var n=this.$d;this.$y=n.getUTCFullYear(),this.$M=n.getUTCMonth(),this.$D=n.getUTCDate(),this.$W=n.getUTCDay(),this.$H=n.getUTCHours(),this.$m=n.getUTCMinutes(),this.$s=n.getUTCSeconds(),this.$ms=n.getUTCMilliseconds()}else S.call(this)};var y=u.utcOffset;u.utcOffset=function(n,A){var b=this.$utils().u;if(b(n))return this.$u?0:b(this.$offset)?y.call(this):this.$offset;if(typeof n=="string"&&(n=function(_){_===void 0&&(_="");var B=_.match(s);if(!B)return null;var T=(""+B[0]).match(l)||["-",0,0],w=T[0],C=60*+T[1]+ +T[2];return C===0?0:w==="+"?C:-C}(n),n===null))return this;var g=Math.abs(n)<=16?60*n:n,v=this;if(A)return v.$offset=g,v.$u=n===0,v;if(n!==0){var k=this.$u?this.toDate().getTimezoneOffset():-1*this.utcOffset();(v=this.local().add(g+k,r)).$offset=g,v.$x.$localOffset=k}else v=this.utc();return v};var m=u.format;u.format=function(n){var A=n||(this.$u?"YYYY-MM-DDTHH:mm:ss[Z]":"");return m.call(this,A)},u.valueOf=function(){var n=this.$utils().u(this.$offset)?0:this.$offset+(this.$x.$localOffset||this.$d.getTimezoneOffset());return this.$d.valueOf()-6e4*n},u.isUTC=function(){return!!this.$u},u.toISOString=function(){return this.toDate().toISOString()},u.toString=function(){return this.toDate().toUTCString()};var f=u.toDate;u.toDate=function(n){return n==="s"&&this.$offset?d(this.format("YYYY-MM-DD HH:mm:ss:SSS")).toDate():f.call(this)};var h=u.diff;u.diff=function(n,A,b){if(n&&this.$u===n.$u)return h.call(this,n,A,b);var g=this.local(),v=d(n).local();return h.call(g,v,A,b)}}})})(ae);const se=ae.exports;var te={exports:{}};(function(e,a){(function(r,s){e.exports=s()})(q,function(){var r={year:0,month:1,day:2,hour:3,minute:4,second:5},s={};return function(l,c,o){var d,u=function(m,f,h){h===void 0&&(h={});var n=new Date(m),A=function(b,g){g===void 0&&(g={});var v=g.timeZoneName||"short",k=b+"|"+v,_=s[k];return _||(_=new Intl.DateTimeFormat("en-US",{hour12:!1,timeZone:b,year:"numeric",month:"2-digit",day:"2-digit",hour:"2-digit",minute:"2-digit",second:"2-digit",timeZoneName:v}),s[k]=_),_}(f,h);return A.formatToParts(n)},E=function(m,f){for(var h=u(m,f),n=[],A=0;A<h.length;A+=1){var b=h[A],g=b.type,v=b.value,k=r[g];k>=0&&(n[k]=parseInt(v,10))}var _=n[3],B=_===24?0:_,T=n[0]+"-"+n[1]+"-"+n[2]+" "+B+":"+n[4]+":"+n[5]+":000",w=+m;return(o.utc(T).valueOf()-(w-=w%1e3))/6e4},S=c.prototype;S.tz=function(m,f){m===void 0&&(m=d);var h=this.utcOffset(),n=this.toDate(),A=n.toLocaleString("en-US",{timeZone:m}),b=Math.round((n-new Date(A))/1e3/60),g=o(A,{locale:this.$L}).$set("millisecond",this.$ms).utcOffset(15*-Math.round(n.getTimezoneOffset()/15)-b,!0);if(f){var v=g.utcOffset();g=g.add(h-v,"minute")}return g.$x.$timezone=m,g},S.offsetName=function(m){var f=this.$x.$timezone||o.tz.guess(),h=u(this.valueOf(),f,{timeZoneName:m}).find(function(n){return n.type.toLowerCase()==="timezonename"});return h&&h.value};var y=S.startOf;S.startOf=function(m,f){if(!this.$x||!this.$x.$timezone)return y.call(this,m,f);var h=o(this.format("YYYY-MM-DD HH:mm:ss:SSS"),{locale:this.$L});return y.call(h,m,f).tz(this.$x.$timezone,!0)},o.tz=function(m,f,h){var n=h&&f,A=h||f||d,b=E(+o(),A);if(typeof m!="string")return o(m).tz(A);var g=function(B,T,w){var C=B-60*T*1e3,D=E(C,w);if(T===D)return[C,T];var I=E(C-=60*(D-T)*1e3,w);return D===I?[C,D]:[B-60*Math.min(D,I)*1e3,Math.max(D,I)]}(o.utc(m,n).valueOf(),b,A),v=g[0],k=g[1],_=o(v).utcOffset(k);return _.$x.$timezone=A,_},o.tz.guess=function(){return Intl.DateTimeFormat().resolvedOptions().timeZone},o.tz.setDefault=function(m){d=m}}})})(te);const ce=te.exports,le=["Africa/Abidjan","Africa/Accra","Africa/Addis_Ababa","Africa/Algiers","Africa/Asmara","Africa/Asmera","Africa/Bamako","Africa/Bangui","Africa/Banjul","Africa/Bissau","Africa/Blantyre","Africa/Brazzaville","Africa/Bujumbura","Africa/Cairo","Africa/Casablanca","Africa/Ceuta","Africa/Conakry","Africa/Dakar","Africa/Dar_es_Salaam","Africa/Djibouti","Africa/Douala","Africa/El_Aaiun","Africa/Freetown","Africa/Gaborone","Africa/Harare","Africa/Johannesburg","Africa/Juba","Africa/Kampala","Africa/Khartoum","Africa/Kigali","Africa/Kinshasa","Africa/Lagos","Africa/Libreville","Africa/Lome","Africa/Luanda","Africa/Lubumbashi","Africa/Lusaka","Africa/Malabo","Africa/Maputo","Africa/Maseru","Africa/Mbabane","Africa/Mogadishu","Africa/Monrovia","Africa/Nairobi","Africa/Ndjamena","Africa/Niamey","Africa/Nouakchott","Africa/Ouagadougou","Africa/Porto-Novo","Africa/Sao_Tome","Africa/Timbuktu","Africa/Tripoli","Africa/Tunis","Africa/Windhoek","America/Adak","America/Anchorage","America/Anguilla","America/Antigua","America/Araguaina","America/Argentina/Buenos_Aires","America/Argentina/Catamarca","America/Argentina/ComodRivadavia","America/Argentina/Cordoba","America/Argentina/Jujuy","America/Argentina/La_Rioja","America/Argentina/Mendoza","America/Argentina/Rio_Gallegos","America/Argentina/Salta","America/Argentina/San_Juan","America/Argentina/San_Luis","America/Argentina/Tucuman","America/Argentina/Ushuaia","America/Aruba","America/Asuncion","America/Atikokan","America/Atka","America/Bahia","America/Bahia_Banderas","America/Barbados","America/Belem","America/Belize","America/Blanc-Sablon","America/Boa_Vista","America/Bogota","America/Boise","America/Buenos_Aires","America/Cambridge_Bay","America/Campo_Grande","America/Cancun","America/Caracas","America/Catamarca","America/Cayenne","America/Cayman","America/Chicago","America/Chihuahua","America/Coral_Harbour","America/Cordoba","America/Costa_Rica","America/Creston","America/Cuiaba","America/Curacao","America/Danmarkshavn","America/Dawson","America/Dawson_Creek","America/Denver","America/Detroit","America/Dominica","America/Edmonton","America/Eirunepe","America/El_Salvador","America/Ensenada","America/Fort_Nelson","America/Fort_Wayne","America/Fortaleza","America/Glace_Bay","America/Godthab","America/Goose_Bay","America/Grand_Turk","America/Grenada","America/Guadeloupe","America/Guatemala","America/Guayaquil","America/Guyana","America/Halifax","America/Havana","America/Hermosillo","America/Indiana/Indianapolis","America/Indiana/Knox","America/Indiana/Marengo","America/Indiana/Petersburg","America/Indiana/Tell_City","America/Indiana/Vevay","America/Indiana/Vincennes","America/Indiana/Winamac","America/Indianapolis","America/Inuvik","America/Iqaluit","America/Jamaica","America/Jujuy","America/Juneau","America/Kentucky/Louisville","America/Kentucky/Monticello","America/Knox_IN","America/Kralendijk","America/La_Paz","America/Lima","America/Los_Angeles","America/Louisville","America/Lower_Princes","America/Maceio","America/Managua","America/Manaus","America/Marigot","America/Martinique","America/Matamoros","America/Mazatlan","America/Mendoza","America/Menominee","America/Merida","America/Metlakatla","America/Mexico_City","America/Miquelon","America/Moncton","America/Monterrey","America/Montevideo","America/Montreal","America/Montserrat","America/Nassau","America/New_York","America/Nipigon","America/Nome","America/Noronha","America/North_Dakota/Beulah","America/North_Dakota/Center","America/North_Dakota/New_Salem","America/Nuuk","America/Ojinaga","America/Panama","America/Pangnirtung","America/Paramaribo","America/Phoenix","America/Port-au-Prince","America/Port_of_Spain","America/Porto_Acre","America/Porto_Velho","America/Puerto_Rico","America/Punta_Arenas","America/Rainy_River","America/Rankin_Inlet","America/Recife","America/Regina","America/Resolute","America/Rio_Branco","America/Rosario","America/Santa_Isabel","America/Santarem","America/Santiago","America/Santo_Domingo","America/Sao_Paulo","America/Scoresbysund","America/Shiprock","America/Sitka","America/St_Barthelemy","America/St_Johns","America/St_Kitts","America/St_Lucia","America/St_Thomas","America/St_Vincent","America/Swift_Current","America/Tegucigalpa","America/Thule","America/Thunder_Bay","America/Tijuana","America/Toronto","America/Tortola","America/Vancouver","America/Virgin","America/Whitehorse","America/Winnipeg","America/Yakutat","America/Yellowknife","Antarctica/Casey","Antarctica/Davis","Antarctica/DumontDUrville","Antarctica/Macquarie","Antarctica/Mawson","Antarctica/McMurdo","Antarctica/Palmer","Antarctica/Rothera","Antarctica/South_Pole","Antarctica/Syowa","Antarctica/Troll","Antarctica/Vostok","Arctic/Longyearbyen","Asia/Aden","Asia/Almaty","Asia/Amman","Asia/Anadyr","Asia/Aqtau","Asia/Aqtobe","Asia/Ashgabat","Asia/Ashkhabad","Asia/Atyrau","Asia/Baghdad","Asia/Bahrain","Asia/Baku","Asia/Bangkok","Asia/Barnaul","Asia/Beirut","Asia/Bishkek","Asia/Brunei","Asia/Calcutta","Asia/Chita","Asia/Choibalsan","Asia/Chongqing","Asia/Chungking","Asia/Colombo","Asia/Dacca","Asia/Damascus","Asia/Dhaka","Asia/Dili","Asia/Dubai","Asia/Dushanbe","Asia/Famagusta","Asia/Gaza","Asia/Harbin","Asia/Hebron","Asia/Ho_Chi_Minh","Asia/Hong_Kong","Asia/Hovd","Asia/Irkutsk","Asia/Istanbul","Asia/Jakarta","Asia/Jayapura","Asia/Jerusalem","Asia/Kabul","Asia/Kamchatka","Asia/Karachi","Asia/Kashgar","Asia/Kathmandu","Asia/Katmandu","Asia/Khandyga","Asia/Kolkata","Asia/Krasnoyarsk","Asia/Kuala_Lumpur","Asia/Kuching","Asia/Kuwait","Asia/Macao","Asia/Macau","Asia/Magadan","Asia/Makassar","Asia/Manila","Asia/Muscat","Asia/Nicosia","Asia/Novokuznetsk","Asia/Novosibirsk","Asia/Omsk","Asia/Oral","Asia/Phnom_Penh","Asia/Pontianak","Asia/Pyongyang","Asia/Qatar","Asia/Qostanay","Asia/Qyzylorda","Asia/Rangoon","Asia/Riyadh","Asia/Saigon","Asia/Sakhalin","Asia/Samarkand","Asia/Seoul","Asia/Shanghai","Asia/Singapore","Asia/Srednekolymsk","Asia/Taipei","Asia/Tashkent","Asia/Tbilisi","Asia/Tehran","Asia/Tel_Aviv","Asia/Thimbu","Asia/Thimphu","Asia/Tokyo","Asia/Tomsk","Asia/Ujung_Pandang","Asia/Ulaanbaatar","Asia/Ulan_Bator","Asia/Urumqi","Asia/Ust-Nera","Asia/Vientiane","Asia/Vladivostok","Asia/Yakutsk","Asia/Yangon","Asia/Yekaterinburg","Asia/Yerevan","Atlantic/Azores","Atlantic/Bermuda","Atlantic/Canary","Atlantic/Cape_Verde","Atlantic/Faeroe","Atlantic/Faroe","Atlantic/Jan_Mayen","Atlantic/Madeira","Atlantic/Reykjavik","Atlantic/South_Georgia","Atlantic/St_Helena","Atlantic/Stanley","Australia/ACT","Australia/Adelaide","Australia/Brisbane","Australia/Broken_Hill","Australia/Canberra","Australia/Currie","Australia/Darwin","Australia/Eucla","Australia/Hobart","Australia/LHI","Australia/Lindeman","Australia/Lord_Howe","Australia/Melbourne","Australia/NSW","Australia/North","Australia/Perth","Australia/Queensland","Australia/South","Australia/Sydney","Australia/Tasmania","Australia/Victoria","Australia/West","Australia/Yancowinna","Brazil/Acre","Brazil/DeNoronha","Brazil/East","Brazil/West","CET","CST6CDT","Canada/Atlantic","Canada/Central","Canada/Eastern","Canada/Mountain","Canada/Newfoundland","Canada/Pacific","Canada/Saskatchewan","Canada/Yukon","Chile/Continental","Chile/EasterIsland","Cuba","EET","EST","EST5EDT","Egypt","Eire","Etc/GMT","Etc/GMT+0","Etc/GMT+1","Etc/GMT+10","Etc/GMT+11","Etc/GMT+12","Etc/GMT+2","Etc/GMT+3","Etc/GMT+4","Etc/GMT+5","Etc/GMT+6","Etc/GMT+7","Etc/GMT+8","Etc/GMT+9","Etc/GMT-0","Etc/GMT-1","Etc/GMT-10","Etc/GMT-11","Etc/GMT-12","Etc/GMT-13","Etc/GMT-14","Etc/GMT-2","Etc/GMT-3","Etc/GMT-4","Etc/GMT-5","Etc/GMT-6","Etc/GMT-7","Etc/GMT-8","Etc/GMT-9","Etc/GMT0","Etc/Greenwich","Etc/UCT","Etc/UTC","Etc/Universal","Etc/Zulu","Europe/Amsterdam","Europe/Andorra","Europe/Astrakhan","Europe/Athens","Europe/Belfast","Europe/Belgrade","Europe/Berlin","Europe/Bratislava","Europe/Brussels","Europe/Bucharest","Europe/Budapest","Europe/Busingen","Europe/Chisinau","Europe/Copenhagen","Europe/Dublin","Europe/Gibraltar","Europe/Guernsey","Europe/Helsinki","Europe/Isle_of_Man","Europe/Istanbul","Europe/Jersey","Europe/Kaliningrad","Europe/Kiev","Europe/Kirov","Europe/Lisbon","Europe/Ljubljana","Europe/London","Europe/Luxembourg","Europe/Madrid","Europe/Malta","Europe/Mariehamn","Europe/Minsk","Europe/Monaco","Europe/Moscow","Europe/Nicosia","Europe/Oslo","Europe/Paris","Europe/Podgorica","Europe/Prague","Europe/Riga","Europe/Rome","Europe/Samara","Europe/San_Marino","Europe/Sarajevo","Europe/Saratov","Europe/Simferopol","Europe/Skopje","Europe/Sofia","Europe/Stockholm","Europe/Tallinn","Europe/Tirane","Europe/Tiraspol","Europe/Ulyanovsk","Europe/Uzhgorod","Europe/Vaduz","Europe/Vatican","Europe/Vienna","Europe/Vilnius","Europe/Volgograd","Europe/Warsaw","Europe/Zagreb","Europe/Zaporozhye","Europe/Zurich","GB","GB-Eire","GMT","GMT+0","GMT-0","GMT0","Greenwich","HST","Hongkong","Iceland","Indian/Antananarivo","Indian/Chagos","Indian/Christmas","Indian/Cocos","Indian/Comoro","Indian/Kerguelen","Indian/Mahe","Indian/Maldives","Indian/Mauritius","Indian/Mayotte","Indian/Reunion","Iran","Israel","Jamaica","Japan","Kwajalein","Libya","MET","MST","MST7MDT","Mexico/BajaNorte","Mexico/BajaSur","Mexico/General","NZ","NZ-CHAT","Navajo","PRC","PST8PDT","Pacific/Apia","Pacific/Auckland","Pacific/Bougainville","Pacific/Chatham","Pacific/Chuuk","Pacific/Easter","Pacific/Efate","Pacific/Enderbury","Pacific/Fakaofo","Pacific/Fiji","Pacific/Funafuti","Pacific/Galapagos","Pacific/Gambier","Pacific/Guadalcanal","Pacific/Guam","Pacific/Honolulu","Pacific/Johnston","Pacific/Kiritimati","Pacific/Kosrae","Pacific/Kwajalein","Pacific/Majuro","Pacific/Marquesas","Pacific/Midway","Pacific/Nauru","Pacific/Niue","Pacific/Norfolk","Pacific/Noumea","Pacific/Pago_Pago","Pacific/Palau","Pacific/Pitcairn","Pacific/Pohnpei","Pacific/Ponape","Pacific/Port_Moresby","Pacific/Rarotonga","Pacific/Saipan","Pacific/Samoa","Pacific/Tahiti","Pacific/Tarawa","Pacific/Tongatapu","Pacific/Truk","Pacific/Wake","Pacific/Wallis","Pacific/Yap","Poland","Portugal","ROC","ROK","Singapore","Turkey","UCT","US/Alaska","US/Aleutian","US/Arizona","US/Central","US/East-Indiana","US/Eastern","US/Hawaii","US/Indiana-Starke","US/Michigan","US/Mountain","US/Pacific","US/Pacific-New","US/Samoa","UTC","Universal","W-SU","WET","Zulu"],ue={props:{index:Number,initialField:Object},data:function(){return{field:this.initialField}},methods:{persistedField:function(){return this.field.id>=1},saveField:function(){let e=this.field;this.persistedField()?p.fetch(`/api/v1/configs/fields/${this.field.id}`,{method:"PATCH",credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"},body:JSON.stringify(e)}).then(a=>a.json()).then(a=>{a.success===!0&&(this.field=a.data,K({title:"Succ\xE8s",body:"Field has been updated!",delay:1e3}))}):p.fetch("/api/v1/configs/fields",{method:"POST",credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"},body:JSON.stringify(e)}).then(a=>a.json()).then(a=>{a.success===!0&&(this.field=a.data,K({title:"Succ\xE8s",body:"Field has been created!",delay:1e3}))})},deleteField:function(){confirm("Are you sure you'd like to delete this field?")&&(this.persistedField()?p.fetch(`/api/v1/configs/fields/${this.field.id}`,{method:"DELETE",credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"}}).then(e=>e.json()).then(e=>{e.success===!0&&this.$emit("remove-field",this.index)}):this.$emit("remove-field",this.index))}}},de={class:"border-bottom"},me=i("span",{"aria-hidden":"true"},"\xD7",-1),fe=[me],he={class:"row"},Ae={class:"col-md-3"},pe={class:"form-group"},ge=i("label",null,"Field Type",-1),ve=i("option",{value:"text"},"Text Field",-1),be=i("option",{value:"boolean"},"Checkbox",-1),_e=[ve,be],ye=i("small",{class:"form-text text-muted"},"Type of field shown to the user",-1),ke={class:"col-md-9"},Te={class:"form-group"},Ee=i("label",null,"Field Name",-1),Se=i("small",{class:"form-text text-muted"},"Field name",-1),Me={class:"col-md-12"},Ce={class:"form-group"},$e=i("label",null,"Field Description",-1),Pe=i("small",{id:"emailHelp",class:"form-text text-muted"},"Field Description",-1),Be={class:"col-md-12"},we={class:"form-check"},ze={class:"form-check-label"},De={class:"form-check"},xe={class:"form-check-label"},Ne={class:"form-check"},je={class:"form-check-label"},Ge={class:"row pb-3"},Oe={class:"col-md-12"},Ie={class:"d-block"};function Fe(e,a,r,s,l,c){return $(),P("div",de,[i("div",null,[i("button",{type:"button",class:"close float-right","aria-label":"Close",onClick:a[0]||(a[0]=o=>c.deleteField())},fe)]),i("div",he,[i("div",Ae,[i("div",pe,[ge,M(i("select",{class:"form-control custom-select","onUpdate:modelValue":a[1]||(a[1]=o=>e.field.field_type=o)},_e,512),[[W,e.field.field_type,void 0,{lazy:!0}]]),ye])]),i("div",ke,[i("div",Te,[Ee,M(i("input",{type:"text",class:"form-control","onUpdate:modelValue":a[2]||(a[2]=o=>e.field.name=o)},null,512),[[j,e.field.name,void 0,{lazy:!0}]]),Se])]),i("div",Me,[i("div",Ce,[$e,M(i("input",{type:"text",class:"form-control","onUpdate:modelValue":a[3]||(a[3]=o=>e.field.description=o)},null,512),[[j,e.field.description,void 0,{lazy:!0}]]),Pe])]),i("div",Be,[i("div",we,[i("label",ze,[M(i("input",{class:"form-check-input",type:"checkbox","onUpdate:modelValue":a[4]||(a[4]=o=>e.field.editable=o)},null,512),[[F,e.field.editable,void 0,{lazy:!0}]]),U(" Editable by user in profile ")])]),i("div",De,[i("label",xe,[M(i("input",{class:"form-check-input",type:"checkbox","onUpdate:modelValue":a[5]||(a[5]=o=>e.field.required=o)},null,512),[[F,e.field.required,void 0,{lazy:!0}]]),U(" Required on registration ")])]),i("div",Ne,[i("label",je,[M(i("input",{class:"form-check-input",type:"checkbox","onUpdate:modelValue":a[6]||(a[6]=o=>e.field.public=o)},null,512),[[F,e.field.public,void 0,{lazy:!0}]]),U(" Shown on public profile ")])])])]),i("div",Ge,[i("div",Oe,[i("div",Ie,[i("button",{class:"btn btn-sm btn-success btn-outlined float-right",type:"button",onClick:a[7]||(a[7]=o=>c.saveField())}," Save ")])])])])}const Ue=G(ue,[["render",Fe]]),Le={name:"FieldList",components:{Field:Ue},props:{type:String},data:function(){return{fields:[]}},methods:{loadFields:function(){p.fetch(`/api/v1/configs/fields?type=${this.type}`,{method:"GET",credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"}}).then(e=>e.json()).then(e=>{this.fields=e.data})},addField:function(){this.fields.push({id:Math.random(),type:this.type,field_type:"text",name:"",description:"",editable:!1,required:!1,public:!1})},removeField:function(e){this.fields.splice(e,1),console.log(this.fields)}},created(){this.loadFields()}},Ve={class:"row"},He={class:"col text-center"};function Ke(e,a,r,s,l,c){const o=Z("Field");return $(),P("div",null,[($(!0),P(Q,null,X(e.fields,(d,u)=>($(),P("div",{class:"mb-5",key:d.id},[ee(o,{index:u,initialField:e.fields[u],onRemoveField:c.removeField},null,8,["index","initialField","onRemoveField"])]))),128)),i("div",Ve,[i("div",He,[i("button",{class:"btn btn-sm btn-success btn-outlined m-auto",type:"button",onClick:a[0]||(a[0]=d=>c.addField())}," Add New Field ")])])])}const Re=G(Le,[["render",Ke]]),Ye={props:{index:Number,initialBracket:Object},data:function(){return{bracket:this.initialBracket}},methods:{persisted:function(){return this.bracket.id>=1},saveBracket:function(){let e=this.bracket,a="",r="",s="";this.persisted()?(a=`/api/v1/brackets/${this.bracket.id}`,r="PATCH",s="Bracket has been updated!"):(a="/api/v1/brackets",r="POST",s="Bracket has been created!"),p.fetch(a,{method:r,credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"},body:JSON.stringify(e)}).then(l=>l.json()).then(l=>{l.success===!0&&(this.field=l.data,K({title:"Succ\xE8s",body:s,delay:1e3}))})},deleteBracket:function(){confirm("Are you sure you'd like to delete this bracket?")&&(this.persisted()?p.fetch(`/api/v1/brackets/${this.bracket.id}`,{method:"DELETE",credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"}}).then(e=>e.json()).then(e=>{e.success===!0&&this.$emit("remove-bracket",this.index)}):this.$emit("remove-bracket",this.index))}}},Je={class:"border-bottom"},qe=i("span",{"aria-hidden":"true"},"\xD7",-1),We=[qe],Ze={class:"row"},Qe={class:"col-md-9"},Xe={class:"form-group"},ea=i("label",null,"Bracket Name",-1),aa=i("small",{class:"form-text text-muted"},' Bracket name (e.g. "Students", "Interns", "Engineers") ',-1),ta={class:"col-md-12"},ia={class:"form-group"},oa=i("label",null,"Bracket Description",-1),na=i("small",{class:"form-text text-muted"},"Bracket Description",-1),ra={class:"col-md-12"},sa=i("label",null,"Bracket Type",-1),ca=i("option",null,null,-1),la=i("option",{value:"users"},"Users",-1),ua=i("option",{value:"teams"},"Teams",-1),da=[ca,la,ua],ma=i("small",{class:"form-text text-muted"}," If you are using Team Mode and would like the bracket to apply to entire teams instead of individuals, select Teams. ",-1),fa={class:"row pb-3"},ha={class:"col-md-12"},Aa={class:"d-block"};function pa(e,a,r,s,l,c){return $(),P("div",Je,[i("div",null,[i("button",{type:"button",class:"close float-right","aria-label":"Close",onClick:a[0]||(a[0]=o=>c.deleteBracket())},We)]),i("div",Ze,[i("div",Qe,[i("div",Xe,[ea,M(i("input",{type:"text",class:"form-control","onUpdate:modelValue":a[1]||(a[1]=o=>e.bracket.name=o)},null,512),[[j,e.bracket.name,void 0,{lazy:!0}]]),aa])]),i("div",ta,[i("div",ia,[oa,M(i("input",{type:"text",class:"form-control","onUpdate:modelValue":a[2]||(a[2]=o=>e.bracket.description=o)},null,512),[[j,e.bracket.description,void 0,{lazy:!0}]]),na])]),i("div",ra,[sa,M(i("select",{class:"custom-select","onUpdate:modelValue":a[3]||(a[3]=o=>e.bracket.type=o)},da,512),[[W,e.bracket.type,void 0,{lazy:!0}]]),ma])]),i("div",fa,[i("div",ha,[i("div",Aa,[i("button",{class:"btn btn-sm btn-success btn-outlined float-right",type:"button",onClick:a[4]||(a[4]=o=>c.saveBracket())}," Save ")])])])])}const ga=G(Ye,[["render",pa]]),va={name:"BracketList",components:{Bracket:ga},data:function(){return{brackets:[]}},methods:{loadBrackets:function(){p.fetch("/api/v1/brackets",{method:"GET",credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"}}).then(e=>e.json()).then(e=>{this.brackets=e.data})},addBracket:function(){this.brackets.push({id:Math.random(),name:"",description:"",type:null})},removeBracket:function(e){this.brackets.splice(e,1)}},created(){this.loadBrackets()}},ba={class:"row"},_a={class:"col text-center"};function ya(e,a,r,s,l,c){const o=Z("Bracket");return $(),P("div",null,[($(!0),P(Q,null,X(e.brackets,(d,u)=>($(),P("div",{class:"mb-5",key:d.id},[ee(o,{index:u,initialBracket:e.brackets[u],onRemoveBracket:c.removeBracket},null,8,["index","initialBracket","onRemoveBracket"])]))),128)),i("div",ba,[i("div",_a,[i("button",{class:"btn btn-sm btn-success btn-outlined m-auto",type:"button",onClick:a[0]||(a[0]=d=>c.addBracket())}," Add New Bracket ")])])])}const ka=G(va,[["render",ya]]);x.extend(re);x.extend(se);x.extend(ce);function V(e,a){typeof a=="string"&&(a=parseInt(a,10)*1e3);const r=x(a);t("#"+e+"-month").val(r.month()+1),t("#"+e+"-day").val(r.date()),t("#"+e+"-year").val(r.year()),t("#"+e+"-hour").val(r.hour()),t("#"+e+"-minute").val(r.minute()),N(e)}function N(e){const a=t("#"+e+"-month").val(),r=t("#"+e+"-day").val(),s=t("#"+e+"-year").val(),l=t("#"+e+"-hour").val(),c=t("#"+e+"-minute").val(),o=t("#"+e+"-timezone").val(),d=Ta(a,r,s,l,c);d.unix()&&a&&r&&s&&l&&c?(t("#"+e).val(d.unix()),t("#"+e+"-local").val(d.format("dddd, MMMM Do YYYY, h:mm:ss a z (zzz)")),t("#"+e+"-zonetime").val(d.tz(o).format("dddd, MMMM Do YYYY, h:mm:ss a z (zzz)"))):(t("#"+e).val(""),t("#"+e+"-local").val(""),t("#"+e+"-zonetime").val(""))}function Ta(e,a,r,s,l){let c=e.toString();c.length==1&&(c="0"+c);let o=a.toString();o.length==1&&(o="0"+o);let d=s.toString();d.length==1&&(d="0"+d);let u=l.toString();u.length==1&&(u="0"+u);const E=r.toString()+"-"+c+"-"+o+" "+d+":"+u+":00";return x(E)}function ie(e){e.preventDefault();const a=t(this).serializeJSON(),r={};a.mail_useauth===!1?(a.mail_username=null,a.mail_password=null):(a.mail_username===""&&delete a.mail_username,a.mail_password===""&&delete a.mail_password),Object.keys(a).forEach(function(s){a[s]==="true"?r[s]=!0:a[s]==="false"?r[s]=!1:r[s]=a[s]}),p.api.patch_config_list({},r).then(function(s){if(s.success)window.location.reload();else{let l=s.errors.value.join(` +import{H as q,_ as G,C as p,D as K,o as $,c as P,a as i,h as M,v as W,l as j,i as F,j as U,e as Z,F as Q,r as X,f as ee,I as x,K as re,$ as t,V as J,B as O,s as R,u as Y,L as z}from"./main.71d0edc5.js";import"../tab.facb6ef1.js";import{c as L}from"../htmlmixed.e85df030.js";var ae={exports:{}};(function(e,a){(function(r,s){e.exports=s()})(q,function(){var r="minute",s=/[+-]\d\d(?::?\d\d)?/g,l=/([+-]|\d\d)/g;return function(c,o,d){var u=o.prototype;d.utc=function(n){var A={date:n,utc:!0,args:arguments};return new o(A)},u.utc=function(n){var A=d(this.toDate(),{locale:this.$L,utc:!0});return n?A.add(this.utcOffset(),r):A},u.local=function(){return d(this.toDate(),{locale:this.$L,utc:!1})};var E=u.parse;u.parse=function(n){n.utc&&(this.$u=!0),this.$utils().u(n.$offset)||(this.$offset=n.$offset),E.call(this,n)};var S=u.init;u.init=function(){if(this.$u){var n=this.$d;this.$y=n.getUTCFullYear(),this.$M=n.getUTCMonth(),this.$D=n.getUTCDate(),this.$W=n.getUTCDay(),this.$H=n.getUTCHours(),this.$m=n.getUTCMinutes(),this.$s=n.getUTCSeconds(),this.$ms=n.getUTCMilliseconds()}else S.call(this)};var y=u.utcOffset;u.utcOffset=function(n,A){var b=this.$utils().u;if(b(n))return this.$u?0:b(this.$offset)?y.call(this):this.$offset;if(typeof n=="string"&&(n=function(_){_===void 0&&(_="");var B=_.match(s);if(!B)return null;var T=(""+B[0]).match(l)||["-",0,0],w=T[0],C=60*+T[1]+ +T[2];return C===0?0:w==="+"?C:-C}(n),n===null))return this;var g=Math.abs(n)<=16?60*n:n,v=this;if(A)return v.$offset=g,v.$u=n===0,v;if(n!==0){var k=this.$u?this.toDate().getTimezoneOffset():-1*this.utcOffset();(v=this.local().add(g+k,r)).$offset=g,v.$x.$localOffset=k}else v=this.utc();return v};var m=u.format;u.format=function(n){var A=n||(this.$u?"YYYY-MM-DDTHH:mm:ss[Z]":"");return m.call(this,A)},u.valueOf=function(){var n=this.$utils().u(this.$offset)?0:this.$offset+(this.$x.$localOffset||this.$d.getTimezoneOffset());return this.$d.valueOf()-6e4*n},u.isUTC=function(){return!!this.$u},u.toISOString=function(){return this.toDate().toISOString()},u.toString=function(){return this.toDate().toUTCString()};var f=u.toDate;u.toDate=function(n){return n==="s"&&this.$offset?d(this.format("YYYY-MM-DD HH:mm:ss:SSS")).toDate():f.call(this)};var h=u.diff;u.diff=function(n,A,b){if(n&&this.$u===n.$u)return h.call(this,n,A,b);var g=this.local(),v=d(n).local();return h.call(g,v,A,b)}}})})(ae);const se=ae.exports;var te={exports:{}};(function(e,a){(function(r,s){e.exports=s()})(q,function(){var r={year:0,month:1,day:2,hour:3,minute:4,second:5},s={};return function(l,c,o){var d,u=function(m,f,h){h===void 0&&(h={});var n=new Date(m),A=function(b,g){g===void 0&&(g={});var v=g.timeZoneName||"short",k=b+"|"+v,_=s[k];return _||(_=new Intl.DateTimeFormat("en-US",{hour12:!1,timeZone:b,year:"numeric",month:"2-digit",day:"2-digit",hour:"2-digit",minute:"2-digit",second:"2-digit",timeZoneName:v}),s[k]=_),_}(f,h);return A.formatToParts(n)},E=function(m,f){for(var h=u(m,f),n=[],A=0;A<h.length;A+=1){var b=h[A],g=b.type,v=b.value,k=r[g];k>=0&&(n[k]=parseInt(v,10))}var _=n[3],B=_===24?0:_,T=n[0]+"-"+n[1]+"-"+n[2]+" "+B+":"+n[4]+":"+n[5]+":000",w=+m;return(o.utc(T).valueOf()-(w-=w%1e3))/6e4},S=c.prototype;S.tz=function(m,f){m===void 0&&(m=d);var h=this.utcOffset(),n=this.toDate(),A=n.toLocaleString("en-US",{timeZone:m}),b=Math.round((n-new Date(A))/1e3/60),g=o(A,{locale:this.$L}).$set("millisecond",this.$ms).utcOffset(15*-Math.round(n.getTimezoneOffset()/15)-b,!0);if(f){var v=g.utcOffset();g=g.add(h-v,"minute")}return g.$x.$timezone=m,g},S.offsetName=function(m){var f=this.$x.$timezone||o.tz.guess(),h=u(this.valueOf(),f,{timeZoneName:m}).find(function(n){return n.type.toLowerCase()==="timezonename"});return h&&h.value};var y=S.startOf;S.startOf=function(m,f){if(!this.$x||!this.$x.$timezone)return y.call(this,m,f);var h=o(this.format("YYYY-MM-DD HH:mm:ss:SSS"),{locale:this.$L});return y.call(h,m,f).tz(this.$x.$timezone,!0)},o.tz=function(m,f,h){var n=h&&f,A=h||f||d,b=E(+o(),A);if(typeof m!="string")return o(m).tz(A);var g=function(B,T,w){var C=B-60*T*1e3,D=E(C,w);if(T===D)return[C,T];var I=E(C-=60*(D-T)*1e3,w);return D===I?[C,D]:[B-60*Math.min(D,I)*1e3,Math.max(D,I)]}(o.utc(m,n).valueOf(),b,A),v=g[0],k=g[1],_=o(v).utcOffset(k);return _.$x.$timezone=A,_},o.tz.guess=function(){return Intl.DateTimeFormat().resolvedOptions().timeZone},o.tz.setDefault=function(m){d=m}}})})(te);const ce=te.exports,le=["Africa/Abidjan","Africa/Accra","Africa/Addis_Ababa","Africa/Algiers","Africa/Asmara","Africa/Asmera","Africa/Bamako","Africa/Bangui","Africa/Banjul","Africa/Bissau","Africa/Blantyre","Africa/Brazzaville","Africa/Bujumbura","Africa/Cairo","Africa/Casablanca","Africa/Ceuta","Africa/Conakry","Africa/Dakar","Africa/Dar_es_Salaam","Africa/Djibouti","Africa/Douala","Africa/El_Aaiun","Africa/Freetown","Africa/Gaborone","Africa/Harare","Africa/Johannesburg","Africa/Juba","Africa/Kampala","Africa/Khartoum","Africa/Kigali","Africa/Kinshasa","Africa/Lagos","Africa/Libreville","Africa/Lome","Africa/Luanda","Africa/Lubumbashi","Africa/Lusaka","Africa/Malabo","Africa/Maputo","Africa/Maseru","Africa/Mbabane","Africa/Mogadishu","Africa/Monrovia","Africa/Nairobi","Africa/Ndjamena","Africa/Niamey","Africa/Nouakchott","Africa/Ouagadougou","Africa/Porto-Novo","Africa/Sao_Tome","Africa/Timbuktu","Africa/Tripoli","Africa/Tunis","Africa/Windhoek","America/Adak","America/Anchorage","America/Anguilla","America/Antigua","America/Araguaina","America/Argentina/Buenos_Aires","America/Argentina/Catamarca","America/Argentina/ComodRivadavia","America/Argentina/Cordoba","America/Argentina/Jujuy","America/Argentina/La_Rioja","America/Argentina/Mendoza","America/Argentina/Rio_Gallegos","America/Argentina/Salta","America/Argentina/San_Juan","America/Argentina/San_Luis","America/Argentina/Tucuman","America/Argentina/Ushuaia","America/Aruba","America/Asuncion","America/Atikokan","America/Atka","America/Bahia","America/Bahia_Banderas","America/Barbados","America/Belem","America/Belize","America/Blanc-Sablon","America/Boa_Vista","America/Bogota","America/Boise","America/Buenos_Aires","America/Cambridge_Bay","America/Campo_Grande","America/Cancun","America/Caracas","America/Catamarca","America/Cayenne","America/Cayman","America/Chicago","America/Chihuahua","America/Coral_Harbour","America/Cordoba","America/Costa_Rica","America/Creston","America/Cuiaba","America/Curacao","America/Danmarkshavn","America/Dawson","America/Dawson_Creek","America/Denver","America/Detroit","America/Dominica","America/Edmonton","America/Eirunepe","America/El_Salvador","America/Ensenada","America/Fort_Nelson","America/Fort_Wayne","America/Fortaleza","America/Glace_Bay","America/Godthab","America/Goose_Bay","America/Grand_Turk","America/Grenada","America/Guadeloupe","America/Guatemala","America/Guayaquil","America/Guyana","America/Halifax","America/Havana","America/Hermosillo","America/Indiana/Indianapolis","America/Indiana/Knox","America/Indiana/Marengo","America/Indiana/Petersburg","America/Indiana/Tell_City","America/Indiana/Vevay","America/Indiana/Vincennes","America/Indiana/Winamac","America/Indianapolis","America/Inuvik","America/Iqaluit","America/Jamaica","America/Jujuy","America/Juneau","America/Kentucky/Louisville","America/Kentucky/Monticello","America/Knox_IN","America/Kralendijk","America/La_Paz","America/Lima","America/Los_Angeles","America/Louisville","America/Lower_Princes","America/Maceio","America/Managua","America/Manaus","America/Marigot","America/Martinique","America/Matamoros","America/Mazatlan","America/Mendoza","America/Menominee","America/Merida","America/Metlakatla","America/Mexico_City","America/Miquelon","America/Moncton","America/Monterrey","America/Montevideo","America/Montreal","America/Montserrat","America/Nassau","America/New_York","America/Nipigon","America/Nome","America/Noronha","America/North_Dakota/Beulah","America/North_Dakota/Center","America/North_Dakota/New_Salem","America/Nuuk","America/Ojinaga","America/Panama","America/Pangnirtung","America/Paramaribo","America/Phoenix","America/Port-au-Prince","America/Port_of_Spain","America/Porto_Acre","America/Porto_Velho","America/Puerto_Rico","America/Punta_Arenas","America/Rainy_River","America/Rankin_Inlet","America/Recife","America/Regina","America/Resolute","America/Rio_Branco","America/Rosario","America/Santa_Isabel","America/Santarem","America/Santiago","America/Santo_Domingo","America/Sao_Paulo","America/Scoresbysund","America/Shiprock","America/Sitka","America/St_Barthelemy","America/St_Johns","America/St_Kitts","America/St_Lucia","America/St_Thomas","America/St_Vincent","America/Swift_Current","America/Tegucigalpa","America/Thule","America/Thunder_Bay","America/Tijuana","America/Toronto","America/Tortola","America/Vancouver","America/Virgin","America/Whitehorse","America/Winnipeg","America/Yakutat","America/Yellowknife","Antarctica/Casey","Antarctica/Davis","Antarctica/DumontDUrville","Antarctica/Macquarie","Antarctica/Mawson","Antarctica/McMurdo","Antarctica/Palmer","Antarctica/Rothera","Antarctica/South_Pole","Antarctica/Syowa","Antarctica/Troll","Antarctica/Vostok","Arctic/Longyearbyen","Asia/Aden","Asia/Almaty","Asia/Amman","Asia/Anadyr","Asia/Aqtau","Asia/Aqtobe","Asia/Ashgabat","Asia/Ashkhabad","Asia/Atyrau","Asia/Baghdad","Asia/Bahrain","Asia/Baku","Asia/Bangkok","Asia/Barnaul","Asia/Beirut","Asia/Bishkek","Asia/Brunei","Asia/Calcutta","Asia/Chita","Asia/Choibalsan","Asia/Chongqing","Asia/Chungking","Asia/Colombo","Asia/Dacca","Asia/Damascus","Asia/Dhaka","Asia/Dili","Asia/Dubai","Asia/Dushanbe","Asia/Famagusta","Asia/Gaza","Asia/Harbin","Asia/Hebron","Asia/Ho_Chi_Minh","Asia/Hong_Kong","Asia/Hovd","Asia/Irkutsk","Asia/Istanbul","Asia/Jakarta","Asia/Jayapura","Asia/Jerusalem","Asia/Kabul","Asia/Kamchatka","Asia/Karachi","Asia/Kashgar","Asia/Kathmandu","Asia/Katmandu","Asia/Khandyga","Asia/Kolkata","Asia/Krasnoyarsk","Asia/Kuala_Lumpur","Asia/Kuching","Asia/Kuwait","Asia/Macao","Asia/Macau","Asia/Magadan","Asia/Makassar","Asia/Manila","Asia/Muscat","Asia/Nicosia","Asia/Novokuznetsk","Asia/Novosibirsk","Asia/Omsk","Asia/Oral","Asia/Phnom_Penh","Asia/Pontianak","Asia/Pyongyang","Asia/Qatar","Asia/Qostanay","Asia/Qyzylorda","Asia/Rangoon","Asia/Riyadh","Asia/Saigon","Asia/Sakhalin","Asia/Samarkand","Asia/Seoul","Asia/Shanghai","Asia/Singapore","Asia/Srednekolymsk","Asia/Taipei","Asia/Tashkent","Asia/Tbilisi","Asia/Tehran","Asia/Tel_Aviv","Asia/Thimbu","Asia/Thimphu","Asia/Tokyo","Asia/Tomsk","Asia/Ujung_Pandang","Asia/Ulaanbaatar","Asia/Ulan_Bator","Asia/Urumqi","Asia/Ust-Nera","Asia/Vientiane","Asia/Vladivostok","Asia/Yakutsk","Asia/Yangon","Asia/Yekaterinburg","Asia/Yerevan","Atlantic/Azores","Atlantic/Bermuda","Atlantic/Canary","Atlantic/Cape_Verde","Atlantic/Faeroe","Atlantic/Faroe","Atlantic/Jan_Mayen","Atlantic/Madeira","Atlantic/Reykjavik","Atlantic/South_Georgia","Atlantic/St_Helena","Atlantic/Stanley","Australia/ACT","Australia/Adelaide","Australia/Brisbane","Australia/Broken_Hill","Australia/Canberra","Australia/Currie","Australia/Darwin","Australia/Eucla","Australia/Hobart","Australia/LHI","Australia/Lindeman","Australia/Lord_Howe","Australia/Melbourne","Australia/NSW","Australia/North","Australia/Perth","Australia/Queensland","Australia/South","Australia/Sydney","Australia/Tasmania","Australia/Victoria","Australia/West","Australia/Yancowinna","Brazil/Acre","Brazil/DeNoronha","Brazil/East","Brazil/West","CET","CST6CDT","Canada/Atlantic","Canada/Central","Canada/Eastern","Canada/Mountain","Canada/Newfoundland","Canada/Pacific","Canada/Saskatchewan","Canada/Yukon","Chile/Continental","Chile/EasterIsland","Cuba","EET","EST","EST5EDT","Egypt","Eire","Etc/GMT","Etc/GMT+0","Etc/GMT+1","Etc/GMT+10","Etc/GMT+11","Etc/GMT+12","Etc/GMT+2","Etc/GMT+3","Etc/GMT+4","Etc/GMT+5","Etc/GMT+6","Etc/GMT+7","Etc/GMT+8","Etc/GMT+9","Etc/GMT-0","Etc/GMT-1","Etc/GMT-10","Etc/GMT-11","Etc/GMT-12","Etc/GMT-13","Etc/GMT-14","Etc/GMT-2","Etc/GMT-3","Etc/GMT-4","Etc/GMT-5","Etc/GMT-6","Etc/GMT-7","Etc/GMT-8","Etc/GMT-9","Etc/GMT0","Etc/Greenwich","Etc/UCT","Etc/UTC","Etc/Universal","Etc/Zulu","Europe/Amsterdam","Europe/Andorra","Europe/Astrakhan","Europe/Athens","Europe/Belfast","Europe/Belgrade","Europe/Berlin","Europe/Bratislava","Europe/Brussels","Europe/Bucharest","Europe/Budapest","Europe/Busingen","Europe/Chisinau","Europe/Copenhagen","Europe/Dublin","Europe/Gibraltar","Europe/Guernsey","Europe/Helsinki","Europe/Isle_of_Man","Europe/Istanbul","Europe/Jersey","Europe/Kaliningrad","Europe/Kiev","Europe/Kirov","Europe/Lisbon","Europe/Ljubljana","Europe/London","Europe/Luxembourg","Europe/Madrid","Europe/Malta","Europe/Mariehamn","Europe/Minsk","Europe/Monaco","Europe/Moscow","Europe/Nicosia","Europe/Oslo","Europe/Paris","Europe/Podgorica","Europe/Prague","Europe/Riga","Europe/Rome","Europe/Samara","Europe/San_Marino","Europe/Sarajevo","Europe/Saratov","Europe/Simferopol","Europe/Skopje","Europe/Sofia","Europe/Stockholm","Europe/Tallinn","Europe/Tirane","Europe/Tiraspol","Europe/Ulyanovsk","Europe/Uzhgorod","Europe/Vaduz","Europe/Vatican","Europe/Vienna","Europe/Vilnius","Europe/Volgograd","Europe/Warsaw","Europe/Zagreb","Europe/Zaporozhye","Europe/Zurich","GB","GB-Eire","GMT","GMT+0","GMT-0","GMT0","Greenwich","HST","Hongkong","Iceland","Indian/Antananarivo","Indian/Chagos","Indian/Christmas","Indian/Cocos","Indian/Comoro","Indian/Kerguelen","Indian/Mahe","Indian/Maldives","Indian/Mauritius","Indian/Mayotte","Indian/Reunion","Iran","Israel","Jamaica","Japan","Kwajalein","Libya","MET","MST","MST7MDT","Mexico/BajaNorte","Mexico/BajaSur","Mexico/General","NZ","NZ-CHAT","Navajo","PRC","PST8PDT","Pacific/Apia","Pacific/Auckland","Pacific/Bougainville","Pacific/Chatham","Pacific/Chuuk","Pacific/Easter","Pacific/Efate","Pacific/Enderbury","Pacific/Fakaofo","Pacific/Fiji","Pacific/Funafuti","Pacific/Galapagos","Pacific/Gambier","Pacific/Guadalcanal","Pacific/Guam","Pacific/Honolulu","Pacific/Johnston","Pacific/Kiritimati","Pacific/Kosrae","Pacific/Kwajalein","Pacific/Majuro","Pacific/Marquesas","Pacific/Midway","Pacific/Nauru","Pacific/Niue","Pacific/Norfolk","Pacific/Noumea","Pacific/Pago_Pago","Pacific/Palau","Pacific/Pitcairn","Pacific/Pohnpei","Pacific/Ponape","Pacific/Port_Moresby","Pacific/Rarotonga","Pacific/Saipan","Pacific/Samoa","Pacific/Tahiti","Pacific/Tarawa","Pacific/Tongatapu","Pacific/Truk","Pacific/Wake","Pacific/Wallis","Pacific/Yap","Poland","Portugal","ROC","ROK","Singapore","Turkey","UCT","US/Alaska","US/Aleutian","US/Arizona","US/Central","US/East-Indiana","US/Eastern","US/Hawaii","US/Indiana-Starke","US/Michigan","US/Mountain","US/Pacific","US/Pacific-New","US/Samoa","UTC","Universal","W-SU","WET","Zulu"],ue={props:{index:Number,initialField:Object},data:function(){return{field:this.initialField}},methods:{persistedField:function(){return this.field.id>=1},saveField:function(){let e=this.field;this.persistedField()?p.fetch(`/api/v1/configs/fields/${this.field.id}`,{method:"PATCH",credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"},body:JSON.stringify(e)}).then(a=>a.json()).then(a=>{a.success===!0&&(this.field=a.data,K({title:"Succ\xE8s",body:"Field has been updated!",delay:1e3}))}):p.fetch("/api/v1/configs/fields",{method:"POST",credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"},body:JSON.stringify(e)}).then(a=>a.json()).then(a=>{a.success===!0&&(this.field=a.data,K({title:"Succ\xE8s",body:"Field has been created!",delay:1e3}))})},deleteField:function(){confirm("Are you sure you'd like to delete this field?")&&(this.persistedField()?p.fetch(`/api/v1/configs/fields/${this.field.id}`,{method:"DELETE",credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"}}).then(e=>e.json()).then(e=>{e.success===!0&&this.$emit("remove-field",this.index)}):this.$emit("remove-field",this.index))}}},de={class:"border-bottom"},me=i("span",{"aria-hidden":"true"},"\xD7",-1),fe=[me],he={class:"row"},Ae={class:"col-md-3"},pe={class:"form-group"},ge=i("label",null,"Field Type",-1),ve=i("option",{value:"text"},"Text Field",-1),be=i("option",{value:"boolean"},"Checkbox",-1),_e=[ve,be],ye=i("small",{class:"form-text text-muted"},"Type of field shown to the user",-1),ke={class:"col-md-9"},Te={class:"form-group"},Ee=i("label",null,"Field Name",-1),Se=i("small",{class:"form-text text-muted"},"Field name",-1),Me={class:"col-md-12"},Ce={class:"form-group"},$e=i("label",null,"Field Description",-1),Pe=i("small",{id:"emailHelp",class:"form-text text-muted"},"Field Description",-1),Be={class:"col-md-12"},we={class:"form-check"},ze={class:"form-check-label"},De={class:"form-check"},xe={class:"form-check-label"},Ne={class:"form-check"},je={class:"form-check-label"},Ge={class:"row pb-3"},Oe={class:"col-md-12"},Ie={class:"d-block"};function Fe(e,a,r,s,l,c){return $(),P("div",de,[i("div",null,[i("button",{type:"button",class:"close float-right","aria-label":"Close",onClick:a[0]||(a[0]=o=>c.deleteField())},fe)]),i("div",he,[i("div",Ae,[i("div",pe,[ge,M(i("select",{class:"form-control custom-select","onUpdate:modelValue":a[1]||(a[1]=o=>e.field.field_type=o)},_e,512),[[W,e.field.field_type,void 0,{lazy:!0}]]),ye])]),i("div",ke,[i("div",Te,[Ee,M(i("input",{type:"text",class:"form-control","onUpdate:modelValue":a[2]||(a[2]=o=>e.field.name=o)},null,512),[[j,e.field.name,void 0,{lazy:!0}]]),Se])]),i("div",Me,[i("div",Ce,[$e,M(i("input",{type:"text",class:"form-control","onUpdate:modelValue":a[3]||(a[3]=o=>e.field.description=o)},null,512),[[j,e.field.description,void 0,{lazy:!0}]]),Pe])]),i("div",Be,[i("div",we,[i("label",ze,[M(i("input",{class:"form-check-input",type:"checkbox","onUpdate:modelValue":a[4]||(a[4]=o=>e.field.editable=o)},null,512),[[F,e.field.editable,void 0,{lazy:!0}]]),U(" Editable by user in profile ")])]),i("div",De,[i("label",xe,[M(i("input",{class:"form-check-input",type:"checkbox","onUpdate:modelValue":a[5]||(a[5]=o=>e.field.required=o)},null,512),[[F,e.field.required,void 0,{lazy:!0}]]),U(" Required on registration ")])]),i("div",Ne,[i("label",je,[M(i("input",{class:"form-check-input",type:"checkbox","onUpdate:modelValue":a[6]||(a[6]=o=>e.field.public=o)},null,512),[[F,e.field.public,void 0,{lazy:!0}]]),U(" Shown on public profile ")])])])]),i("div",Ge,[i("div",Oe,[i("div",Ie,[i("button",{class:"btn btn-sm btn-success btn-outlined float-right",type:"button",onClick:a[7]||(a[7]=o=>c.saveField())}," Save ")])])])])}const Ue=G(ue,[["render",Fe]]),Le={name:"FieldList",components:{Field:Ue},props:{type:String},data:function(){return{fields:[]}},methods:{loadFields:function(){p.fetch(`/api/v1/configs/fields?type=${this.type}`,{method:"GET",credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"}}).then(e=>e.json()).then(e=>{this.fields=e.data})},addField:function(){this.fields.push({id:Math.random(),type:this.type,field_type:"text",name:"",description:"",editable:!1,required:!1,public:!1})},removeField:function(e){this.fields.splice(e,1),console.log(this.fields)}},created(){this.loadFields()}},Ve={class:"row"},He={class:"col text-center"};function Ke(e,a,r,s,l,c){const o=Z("Field");return $(),P("div",null,[($(!0),P(Q,null,X(e.fields,(d,u)=>($(),P("div",{class:"mb-5",key:d.id},[ee(o,{index:u,initialField:e.fields[u],onRemoveField:c.removeField},null,8,["index","initialField","onRemoveField"])]))),128)),i("div",Ve,[i("div",He,[i("button",{class:"btn btn-sm btn-success btn-outlined m-auto",type:"button",onClick:a[0]||(a[0]=d=>c.addField())}," Add New Field ")])])])}const Re=G(Le,[["render",Ke]]),Ye={props:{index:Number,initialBracket:Object},data:function(){return{bracket:this.initialBracket}},methods:{persisted:function(){return this.bracket.id>=1},saveBracket:function(){let e=this.bracket,a="",r="",s="";this.persisted()?(a=`/api/v1/brackets/${this.bracket.id}`,r="PATCH",s="Bracket has been updated!"):(a="/api/v1/brackets",r="POST",s="Bracket has been created!"),p.fetch(a,{method:r,credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"},body:JSON.stringify(e)}).then(l=>l.json()).then(l=>{l.success===!0&&(this.field=l.data,K({title:"Succ\xE8s",body:s,delay:1e3}))})},deleteBracket:function(){confirm("Are you sure you'd like to delete this bracket?")&&(this.persisted()?p.fetch(`/api/v1/brackets/${this.bracket.id}`,{method:"DELETE",credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"}}).then(e=>e.json()).then(e=>{e.success===!0&&this.$emit("remove-bracket",this.index)}):this.$emit("remove-bracket",this.index))}}},Je={class:"border-bottom"},qe=i("span",{"aria-hidden":"true"},"\xD7",-1),We=[qe],Ze={class:"row"},Qe={class:"col-md-9"},Xe={class:"form-group"},ea=i("label",null,"Bracket Name",-1),aa=i("small",{class:"form-text text-muted"},' Bracket name (e.g. "Students", "Interns", "Engineers") ',-1),ta={class:"col-md-12"},ia={class:"form-group"},oa=i("label",null,"Bracket Description",-1),na=i("small",{class:"form-text text-muted"},"Bracket Description",-1),ra={class:"col-md-12"},sa=i("label",null,"Bracket Type",-1),ca=i("option",null,null,-1),la=i("option",{value:"users"},"Users",-1),ua=i("option",{value:"teams"},"Teams",-1),da=[ca,la,ua],ma=i("small",{class:"form-text text-muted"}," If you are using Team Mode and would like the bracket to apply to entire teams instead of individuals, select Teams. ",-1),fa={class:"row pb-3"},ha={class:"col-md-12"},Aa={class:"d-block"};function pa(e,a,r,s,l,c){return $(),P("div",Je,[i("div",null,[i("button",{type:"button",class:"close float-right","aria-label":"Close",onClick:a[0]||(a[0]=o=>c.deleteBracket())},We)]),i("div",Ze,[i("div",Qe,[i("div",Xe,[ea,M(i("input",{type:"text",class:"form-control","onUpdate:modelValue":a[1]||(a[1]=o=>e.bracket.name=o)},null,512),[[j,e.bracket.name,void 0,{lazy:!0}]]),aa])]),i("div",ta,[i("div",ia,[oa,M(i("input",{type:"text",class:"form-control","onUpdate:modelValue":a[2]||(a[2]=o=>e.bracket.description=o)},null,512),[[j,e.bracket.description,void 0,{lazy:!0}]]),na])]),i("div",ra,[sa,M(i("select",{class:"custom-select","onUpdate:modelValue":a[3]||(a[3]=o=>e.bracket.type=o)},da,512),[[W,e.bracket.type,void 0,{lazy:!0}]]),ma])]),i("div",fa,[i("div",ha,[i("div",Aa,[i("button",{class:"btn btn-sm btn-success btn-outlined float-right",type:"button",onClick:a[4]||(a[4]=o=>c.saveBracket())}," Save ")])])])])}const ga=G(Ye,[["render",pa]]),va={name:"BracketList",components:{Bracket:ga},data:function(){return{brackets:[]}},methods:{loadBrackets:function(){p.fetch("/api/v1/brackets",{method:"GET",credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"}}).then(e=>e.json()).then(e=>{this.brackets=e.data})},addBracket:function(){this.brackets.push({id:Math.random(),name:"",description:"",type:null})},removeBracket:function(e){this.brackets.splice(e,1)}},created(){this.loadBrackets()}},ba={class:"row"},_a={class:"col text-center"};function ya(e,a,r,s,l,c){const o=Z("Bracket");return $(),P("div",null,[($(!0),P(Q,null,X(e.brackets,(d,u)=>($(),P("div",{class:"mb-5",key:d.id},[ee(o,{index:u,initialBracket:e.brackets[u],onRemoveBracket:c.removeBracket},null,8,["index","initialBracket","onRemoveBracket"])]))),128)),i("div",ba,[i("div",_a,[i("button",{class:"btn btn-sm btn-success btn-outlined m-auto",type:"button",onClick:a[0]||(a[0]=d=>c.addBracket())}," Add New Bracket ")])])])}const ka=G(va,[["render",ya]]);x.extend(re);x.extend(se);x.extend(ce);function V(e,a){typeof a=="string"&&(a=parseInt(a,10)*1e3);const r=x(a);t("#"+e+"-month").val(r.month()+1),t("#"+e+"-day").val(r.date()),t("#"+e+"-year").val(r.year()),t("#"+e+"-hour").val(r.hour()),t("#"+e+"-minute").val(r.minute()),N(e)}function N(e){const a=t("#"+e+"-month").val(),r=t("#"+e+"-day").val(),s=t("#"+e+"-year").val(),l=t("#"+e+"-hour").val(),c=t("#"+e+"-minute").val(),o=t("#"+e+"-timezone").val(),d=Ta(a,r,s,l,c);d.unix()&&a&&r&&s&&l&&c?(t("#"+e).val(d.unix()),t("#"+e+"-local").val(d.format("dddd, MMMM Do YYYY, h:mm:ss a z (zzz)")),t("#"+e+"-zonetime").val(d.tz(o).format("dddd, MMMM Do YYYY, h:mm:ss a z (zzz)"))):(t("#"+e).val(""),t("#"+e+"-local").val(""),t("#"+e+"-zonetime").val(""))}function Ta(e,a,r,s,l){let c=e.toString();c.length==1&&(c="0"+c);let o=a.toString();o.length==1&&(o="0"+o);let d=s.toString();d.length==1&&(d="0"+d);let u=l.toString();u.length==1&&(u="0"+u);const E=r.toString()+"-"+c+"-"+o+" "+d+":"+u+":00";return x(E)}function ie(e){e.preventDefault();const a=t(this).serializeJSON(),r={};a.mail_useauth===!1?(a.mail_username=null,a.mail_password=null):(a.mail_username===""&&delete a.mail_username,a.mail_password===""&&delete a.mail_password),Object.keys(a).forEach(function(s){a[s]==="true"?r[s]=!0:a[s]==="false"?r[s]=!1:r[s]=a[s]}),p.api.patch_config_list({},r).then(function(s){if(s.success)window.location.reload();else{let l=s.errors.value.join(` `);O({title:"Erreur!",body:l,button:"Ok"})}})}function Ea(e){oe(e,1)}function Sa(e){oe(e,2)}function oe(e,a){e.preventDefault();let r=e.target;R.files.upload(r,{},function(s){const c={value:s.data[0].location};p.fetch("/api/v1/configs/ctf_sponsord"+a,{method:"PATCH",body:JSON.stringify(c)}).then(function(o){return o.json()}).then(function(o){o.success?window.location.reload():O({title:"Erreur!",body:"L'envoi du logo a \xE9chou\xE9!",button:"Ok"})})})}function Ma(e){e.preventDefault();let a=new FormData(e.target),r=`\xCAtes-vous s\xFBr que vous souhaitez changer de modes utilisateur? Les soumissions, les r\xE9compenses, les d\xE9verrouilles et le suivi seront supprim\xE9s!`;a.get("user_mode")=="users"&&(r=`\xCAtes-vous s\xFBr que vous souhaitez changer de modes utilisateur? Les \xE9quipes Nall, les soumissions, les r\xE9compenses, les d\xE9verrouilles et le suivi seront supprim\xE9s!`),confirm(r)&&(a.append("submissions",!0),a.append("nonce",p.config.csrfNonce),fetch(p.config.urlRoot+"/admin/reset",{method:"POST",credentials:"same-origin",body:a}),ie.bind(this)(e))}function Ca(){ne(1)}function $a(){ne(2)}function ne(e){Y({title:"Retirer Sponsor"+e,body:"\xCAtes-vous s\xFBr que vous souhaitez supprimer le sponsor?",success:function(){const a={value:null};p.api.patch_config({configKey:"ctf_sponsord"+e},a).then(r=>{window.location.reload()})}})}function Pa(e){e.preventDefault();let a=e.target;R.files.upload(a,{},function(r){const l={value:r.data[0].location};p.fetch("/api/v1/configs/ctf_banner",{method:"PATCH",body:JSON.stringify(l)}).then(function(c){return c.json()}).then(function(c){c.success?window.location.reload():O({title:"Erreur!",body:"L'envoi de banni\xE8re a \xE9chou\xE9!",button:"Ok"})})})}function Ba(){Y({title:"Supprimer la banni\xE8re",body:"\xCAtes-vous s\xFBr que vous souhaitez retirer la banni\xE8re?",success:function(){const e={value:null};p.api.patch_config({configKey:"ctf_banner"},e).then(a=>{window.location.reload()})}})}function wa(e){e.preventDefault();let a=e.target;R.files.upload(a,{},function(r){const l={value:r.data[0].location};p.fetch("/api/v1/configs/ctf_small_icon",{method:"PATCH",body:JSON.stringify(l)}).then(function(c){return c.json()}).then(function(c){c.success?window.location.reload():O({title:"Erreur!",body:"L'envoi d'ic\xF4nes a \xE9chou\xE9!",button:"Ok"})})})}function za(){Y({title:"Supprimer le logo",body:"\xCAtes-vous s\xFBr que vous souhaitez supprimer le petit ic\xF4ne du site?",success:function(){const e={value:null};p.api.patch_config({configKey:"ctf_small_icon"},e).then(a=>{window.location.reload()})}})}function Da(e){e.preventDefault();let a=document.getElementById("import-csv-file").files[0],r=document.getElementById("import-csv-type").value,s=new FormData;s.append("csv_file",a),s.append("csv_type",r),s.append("nonce",p.config.csrfNonce);let l=z({width:0,title:"Progr\xE8s de l'envoi"});t.ajax({url:p.config.urlRoot+"/admin/import/csv",type:"POST",data:s,processData:!1,contentType:!1,statusCode:{500:function(c){let o=JSON.parse(c.responseText),d="";o.forEach(u=>{d+=`Ligne ${u[0]}: ${JSON.stringify(u[1])} diff --git a/CTFd/themes/admin/static/assets/pages/editor.4da035f7.js b/CTFd/themes/admin/static/assets/pages/editor.5cc4e4af.js similarity index 87% rename from CTFd/themes/admin/static/assets/pages/editor.4da035f7.js rename to CTFd/themes/admin/static/assets/pages/editor.5cc4e4af.js index 4c1a64ffd2d574bd1b4b80b9a86b8785332c5903..0ae74661d47d93a650aefb0530c9cc7942abf42d 100644 --- a/CTFd/themes/admin/static/assets/pages/editor.4da035f7.js +++ b/CTFd/themes/admin/static/assets/pages/editor.5cc4e4af.js @@ -1,3 +1,3 @@ -import{$ as t,M as s,V as m,C as r,B as p,D as l}from"./main.9b987665.js";import{c as u}from"../htmlmixed.abcfee66.js";import{C as f}from"../CommentBox.d08ed1e6.js";function g(){window.editor.save();var e=t("#page-edit").serializeJSON(),o="/api/v1/pages",n="POST";let d=window.location.pathname.split("/").pop();d!=="new"&&(o+="/"+d,n="PATCH"),e.link_target===""&&(e.link_target=null),r.fetch(o,{method:n,credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"},body:JSON.stringify(e)}).then(function(i){return i.json()}).then(function(i){if(i.success===!1){let a="";for(const c in i.errors)a+=i.errors[c].join(` +import{$ as t,M as s,V as m,C as r,B as p,D as l}from"./main.71d0edc5.js";import{c as u}from"../htmlmixed.e85df030.js";import{C as f}from"../CommentBox.f5ce8d13.js";function g(){window.editor.save();var e=t("#page-edit").serializeJSON(),o="/api/v1/pages",n="POST";let d=window.location.pathname.split("/").pop();d!=="new"&&(o+="/"+d,n="PATCH"),e.link_target===""&&(e.link_target=null),r.fetch(o,{method:n,credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"},body:JSON.stringify(e)}).then(function(i){return i.json()}).then(function(i){if(i.success===!1){let a="";for(const c in i.errors)a+=i.errors[c].join(` `),a+=` `;p({title:"Erreur",body:a,button:"Ok"});return}n==="PATCH"&&i.success?l({title:"Enregistr\xE9",body:"Vos modifications ont \xE9t\xE9 enregistr\xE9es"}):window.location=r.config.urlRoot+"/admin/pages/"+i.data.id})}function w(){window.editor.save(),t("#page-edit").attr("action",r.config.urlRoot+"/admin/pages/preview"),t("#page-edit").attr("target","_blank"),t("#page-edit").submit()}t(()=>{if(window.editor=u.fromTextArea(document.getElementById("admin-pages-editor"),{lineNumbers:!0,lineWrapping:!0,mode:"htmlmixed",htmlMode:!0}),t("#media-button").click(function(e){s(window.editor)}),t("#save-page").click(function(e){e.preventDefault(),g()}),t(".preview-page").click(function(){w()}),window.PAGE_ID){const e=m.extend(f);let o=document.createElement("div");document.querySelector("#comment-box").appendChild(o),new e({propsData:{type:"page",id:window.PAGE_ID}}).$mount(o)}}); diff --git a/CTFd/themes/admin/static/assets/pages/main.9b987665.js b/CTFd/themes/admin/static/assets/pages/main.71d0edc5.js similarity index 99% rename from CTFd/themes/admin/static/assets/pages/main.9b987665.js rename to CTFd/themes/admin/static/assets/pages/main.71d0edc5.js index e37d1e22b7d396b2a5dd6e83c0c15fe83d1b8108..92c0c97a1a311e4b2f51d8cc1fba7615fe3a3ed6 100644 --- a/CTFd/themes/admin/static/assets/pages/main.9b987665.js +++ b/CTFd/themes/admin/static/assets/pages/main.71d0edc5.js @@ -260,4 +260,4 @@ Please report this to https://github.com/markedjs/marked.`,ge){var ee="<p>An err ----- `]},XB={link:"URL for the link:",image:"URL of the image:"},ZB={locale:"en-US",format:{hour:"2-digit",minute:"2-digit"}},JB={bold:"**",code:"```",italic:"*"},eU={sbInit:"Attach files by drag and dropping or pasting from clipboard.",sbOnDragEnter:"Drop image to upload it.",sbOnDrop:"Uploading image #images_names#...",sbProgress:"Uploading #file_name#: #progress#%",sbOnUploaded:"Uploaded #image_name#",sizeUnits:" B, KB, MB"},tU={noFileGiven:"You must select a file.",typeNotAllowed:"This image type is not allowed.",fileTooLarge:`Image #image_name# is too big (#image_size#). -Maximum file size is #image_max_size#.`,importError:"Something went wrong when uploading the image #image_name#."};function It(e){e=e||{},e.parent=this;var t=!0;if(e.autoDownloadFontAwesome===!1&&(t=!1),e.autoDownloadFontAwesome!==!0)for(var n=document.styleSheets,r=0;r<n.length;r++)!n[r].href||n[r].href.indexOf("//maxcdn.bootstrapcdn.com/font-awesome/")>-1&&(t=!1);if(t){var a=document.createElement("link");a.rel="stylesheet",a.href="https://maxcdn.bootstrapcdn.com/font-awesome/latest/css/font-awesome.min.css",document.getElementsByTagName("head")[0].appendChild(a)}if(e.element)this.element=e.element;else if(e.element===null){console.log("EasyMDE: Error. No element was found.");return}if(e.toolbar===void 0){e.toolbar=[];for(var o in Ms)Object.prototype.hasOwnProperty.call(Ms,o)&&(o.indexOf("separator-")!=-1&&e.toolbar.push("|"),(Ms[o].default===!0||e.showIcons&&e.showIcons.constructor===Array&&e.showIcons.indexOf(o)!=-1)&&e.toolbar.push(o))}if(Object.prototype.hasOwnProperty.call(e,"previewClass")||(e.previewClass="editor-preview"),Object.prototype.hasOwnProperty.call(e,"status")||(e.status=["autosave","lines","words","cursor"],e.uploadImage&&e.status.unshift("upload-image")),e.previewRender||(e.previewRender=function(u){return this.parent.markdown(u)}),e.parsingConfig=go({highlightFormatting:!0},e.parsingConfig||{}),e.insertTexts=go({},jB,e.insertTexts||{}),e.promptTexts=go({},XB,e.promptTexts||{}),e.blockStyles=go({},JB,e.blockStyles||{}),e.autosave!=null&&(e.autosave.timeFormat=go({},ZB,e.autosave.timeFormat||{})),e.iconClassMap=go({},In,e.iconClassMap||{}),e.shortcuts=go({},qB,e.shortcuts||{}),e.maxHeight=e.maxHeight||void 0,e.direction=e.direction||"ltr",typeof e.maxHeight<"u"?e.minHeight=e.maxHeight:e.minHeight=e.minHeight||"300px",e.errorCallback=e.errorCallback||function(u){alert(u)},e.uploadImage=e.uploadImage||!1,e.imageMaxSize=e.imageMaxSize||2097152,e.imageAccept=e.imageAccept||"image/png, image/jpeg, image/gif, image/avif",e.imageTexts=go({},eU,e.imageTexts||{}),e.errorMessages=go({},tU,e.errorMessages||{}),e.imagePathAbsolute=e.imagePathAbsolute||!1,e.imageCSRFName=e.imageCSRFName||"csrfmiddlewaretoken",e.imageCSRFHeader=e.imageCSRFHeader||!1,e.autosave!=null&&e.autosave.unique_id!=null&&e.autosave.unique_id!=""&&(e.autosave.uniqueId=e.autosave.unique_id),e.overlayMode&&e.overlayMode.combine===void 0&&(e.overlayMode.combine=!0),this.options=e,this.render(),e.initialValue&&(!this.options.autosave||this.options.autosave.foundSavedValue!==!0)&&this.value(e.initialValue),e.uploadImage){var l=this;this.codemirror.on("dragenter",function(u,c){l.updateStatusBar("upload-image",l.options.imageTexts.sbOnDragEnter),c.stopPropagation(),c.preventDefault()}),this.codemirror.on("dragend",function(u,c){l.updateStatusBar("upload-image",l.options.imageTexts.sbInit),c.stopPropagation(),c.preventDefault()}),this.codemirror.on("dragleave",function(u,c){l.updateStatusBar("upload-image",l.options.imageTexts.sbInit),c.stopPropagation(),c.preventDefault()}),this.codemirror.on("dragover",function(u,c){l.updateStatusBar("upload-image",l.options.imageTexts.sbOnDragEnter),c.stopPropagation(),c.preventDefault()}),this.codemirror.on("drop",function(u,c){c.stopPropagation(),c.preventDefault(),e.imageUploadFunction?l.uploadImagesUsingCustomFunction(e.imageUploadFunction,c.dataTransfer.files):l.uploadImages(c.dataTransfer.files)}),this.codemirror.on("paste",function(u,c){e.imageUploadFunction?l.uploadImagesUsingCustomFunction(e.imageUploadFunction,c.clipboardData.files):l.uploadImages(c.clipboardData.files)})}}It.prototype.uploadImages=function(e,t,n){if(e.length!==0){for(var r=[],a=0;a<e.length;a++)r.push(e[a].name),this.uploadImage(e[a],t,n);this.updateStatusBar("upload-image",this.options.imageTexts.sbOnDrop.replace("#images_names#",r.join(", ")))}};It.prototype.uploadImagesUsingCustomFunction=function(e,t){if(t.length!==0){for(var n=[],r=0;r<t.length;r++)n.push(t[r].name),this.uploadImageUsingCustomFunction(e,t[r]);this.updateStatusBar("upload-image",this.options.imageTexts.sbOnDrop.replace("#images_names#",n.join(", ")))}};It.prototype.updateStatusBar=function(e,t){if(!!this.gui.statusbar){var n=this.gui.statusbar.getElementsByClassName(e);n.length===1?this.gui.statusbar.getElementsByClassName(e)[0].textContent=t:n.length===0?console.log("EasyMDE: status bar item "+e+" was not found."):console.log("EasyMDE: Several status bar items named "+e+" was found.")}};It.prototype.markdown=function(e){if(Zg){var t;if(this.options&&this.options.renderingConfig&&this.options.renderingConfig.markedOptions?t=this.options.renderingConfig.markedOptions:t={},this.options&&this.options.renderingConfig&&this.options.renderingConfig.singleLineBreaks===!1?t.breaks=!1:t.breaks=!0,this.options&&this.options.renderingConfig&&this.options.renderingConfig.codeSyntaxHighlighting===!0){var n=this.options.renderingConfig.hljs||window.hljs;n&&(t.highlight=function(a,o){return o&&n.getLanguage(o)?n.highlight(o,a).value:n.highlightAuto(a).value})}Zg.setOptions(t);var r=Zg.parse(e);return this.options.renderingConfig&&typeof this.options.renderingConfig.sanitizerFunction=="function"&&(r=this.options.renderingConfig.sanitizerFunction.call(this,r)),r=WB(r),r=VB(r),r}};It.prototype.render=function(e){if(e||(e=this.element||document.getElementsByTagName("textarea")[0]),this._rendered&&this._rendered===e)return;this.element=e;var t=this.options,n=this,r={};for(var a in t.shortcuts)t.shortcuts[a]!==null&&Ku[a]!==null&&function(v){r[fR(t.shortcuts[v])]=function(){var A=Ku[v];typeof A=="function"?A(n):typeof A=="string"&&window.open(A,"_blank")}}(a);r.Enter="newlineAndIndentContinueMarkdownList",r.Tab="tabAndIndentMarkdownList",r["Shift-Tab"]="shiftTabAndUnindentMarkdownList",r.Esc=function(v){v.getOption("fullScreen")&&zs(n)},this.documentOnKeyDown=function(v){v=v||window.event,v.keyCode==27&&n.codemirror.getOption("fullScreen")&&zs(n)},document.addEventListener("keydown",this.documentOnKeyDown,!1);var o,l;t.overlayMode?(vl.defineMode("overlay-mode",function(v){return vl.overlayMode(vl.getMode(v,t.spellChecker!==!1?"spell-checker":"gfm"),t.overlayMode.mode,t.overlayMode.combine)}),o="overlay-mode",l=t.parsingConfig,l.gitHubSpice=!1):(o=t.parsingConfig,o.name="gfm",o.gitHubSpice=!1),t.spellChecker!==!1&&(o="spell-checker",l=t.parsingConfig,l.name="gfm",l.gitHubSpice=!1,typeof t.spellChecker=="function"?t.spellChecker({codeMirrorInstance:vl}):GB({codeMirrorInstance:vl}));function u(v,A,O){return{addNew:!1}}if(this.codemirror=vl.fromTextArea(e,{mode:o,backdrop:l,theme:t.theme!=null?t.theme:"easymde",tabSize:t.tabSize!=null?t.tabSize:2,indentUnit:t.tabSize!=null?t.tabSize:2,indentWithTabs:t.indentWithTabs!==!1,lineNumbers:t.lineNumbers===!0,autofocus:t.autofocus===!0,extraKeys:r,direction:t.direction,lineWrapping:t.lineWrapping!==!1,allowDropFileTypes:["text/plain"],placeholder:t.placeholder||e.getAttribute("placeholder")||"",styleSelectedText:t.styleSelectedText!=null?t.styleSelectedText:!wh(),scrollbarStyle:t.scrollbarStyle!=null?t.scrollbarStyle:"native",configureMouse:u,inputStyle:t.inputStyle!=null?t.inputStyle:wh()?"contenteditable":"textarea",spellcheck:t.nativeSpellcheck!=null?t.nativeSpellcheck:!0,autoRefresh:t.autoRefresh!=null?t.autoRefresh:!1}),this.codemirror.getScrollerElement().style.minHeight=t.minHeight,typeof t.maxHeight<"u"&&(this.codemirror.getScrollerElement().style.height=t.maxHeight),t.forceSync===!0){var c=this.codemirror;c.on("change",function(){c.save()})}this.gui={};var d=document.createElement("div");d.classList.add("EasyMDEContainer"),d.setAttribute("role","application");var S=this.codemirror.getWrapperElement();S.parentNode.insertBefore(d,S),d.appendChild(S),t.toolbar!==!1&&(this.gui.toolbar=this.createToolbar()),t.status!==!1&&(this.gui.statusbar=this.createStatusbar()),t.autosave!=null&&t.autosave.enabled===!0&&(this.autosave(),this.codemirror.on("change",function(){clearTimeout(n._autosave_timeout),n._autosave_timeout=setTimeout(function(){n.autosave()},n.options.autosave.submit_delay||n.options.autosave.delay||1e3)}));function _(v,A){var O,N=window.getComputedStyle(document.querySelector(".CodeMirror-sizer")).width.replace("px","");return v<N?O=A+"px":O=A/v*100+"%",O}var E=this;function T(v,A){v.setAttribute("data-img-src",A.url),v.setAttribute("style","--bg-image:url("+A.url+");--width:"+A.naturalWidth+"px;--height:"+_(A.naturalWidth,A.naturalHeight)),E.codemirror.setSize()}function y(){!t.previewImagesInEditor||d.querySelectorAll(".cm-image-marker").forEach(function(v){var A=v.parentElement;if(!!A.innerText.match(/^!\[.*?\]\(.*\)/g)&&!A.hasAttribute("data-img-src")){var O=A.innerText.match("\\((.*)\\)");if(window.EMDEimagesCache||(window.EMDEimagesCache={}),O&&O.length>=2){var N=O[1];if(t.imagesPreviewHandler){var R=t.imagesPreviewHandler(O[1]);typeof R=="string"&&(N=R)}if(window.EMDEimagesCache[N])T(A,window.EMDEimagesCache[N]);else{var L=document.createElement("img");L.onload=function(){window.EMDEimagesCache[N]={naturalWidth:L.naturalWidth,naturalHeight:L.naturalHeight,url:N},T(A,window.EMDEimagesCache[N])},L.src=N}}}})}this.codemirror.on("update",function(){y()}),this.gui.sideBySide=this.createSideBySide(),this._rendered=this.element,(t.autofocus===!0||e.autofocus)&&this.codemirror.focus();var M=this.codemirror;setTimeout(function(){M.refresh()}.bind(M),0)};It.prototype.cleanup=function(){document.removeEventListener("keydown",this.documentOnKeyDown)};function hR(){if(typeof localStorage=="object")try{localStorage.setItem("smde_localStorage",1),localStorage.removeItem("smde_localStorage")}catch{return!1}else return!1;return!0}It.prototype.autosave=function(){if(hR()){var e=this;if(this.options.autosave.uniqueId==null||this.options.autosave.uniqueId==""){console.log("EasyMDE: You must set a uniqueId to use the autosave feature");return}this.options.autosave.binded!==!0&&(e.element.form!=null&&e.element.form!=null&&e.element.form.addEventListener("submit",function(){clearTimeout(e.autosaveTimeoutId),e.autosaveTimeoutId=void 0,localStorage.removeItem("smde_"+e.options.autosave.uniqueId)}),this.options.autosave.binded=!0),this.options.autosave.loaded!==!0&&(typeof localStorage.getItem("smde_"+this.options.autosave.uniqueId)=="string"&&localStorage.getItem("smde_"+this.options.autosave.uniqueId)!=""&&(this.codemirror.setValue(localStorage.getItem("smde_"+this.options.autosave.uniqueId)),this.options.autosave.foundSavedValue=!0),this.options.autosave.loaded=!0);var t=e.value();t!==""?localStorage.setItem("smde_"+this.options.autosave.uniqueId,t):localStorage.removeItem("smde_"+this.options.autosave.uniqueId);var n=document.getElementById("autosaved");if(n!=null&&n!=null&&n!=""){var r=new Date,a=new Intl.DateTimeFormat([this.options.autosave.timeFormat.locale,"en-US"],this.options.autosave.timeFormat.format).format(r),o=this.options.autosave.text==null?"Autosaved: ":this.options.autosave.text;n.innerHTML=o+a}}else console.log("EasyMDE: localStorage not available, cannot autosave")};It.prototype.clearAutosavedValue=function(){if(hR()){if(this.options.autosave==null||this.options.autosave.uniqueId==null||this.options.autosave.uniqueId==""){console.log("EasyMDE: You must set a uniqueId to clear the autosave value");return}localStorage.removeItem("smde_"+this.options.autosave.uniqueId)}else console.log("EasyMDE: localStorage not available, cannot autosave")};It.prototype.openBrowseFileWindow=function(e,t){var n=this,r=this.gui.toolbar.getElementsByClassName("imageInput")[0];r.click();function a(o){n.options.imageUploadFunction?n.uploadImagesUsingCustomFunction(n.options.imageUploadFunction,o.target.files):n.uploadImages(o.target.files,e,t),r.removeEventListener("change",a)}r.addEventListener("change",a)};It.prototype.uploadImage=function(e,t,n){var r=this;t=t||function(d){_R(r,d)};function a(c){r.updateStatusBar("upload-image",c),setTimeout(function(){r.updateStatusBar("upload-image",r.options.imageTexts.sbInit)},1e4),n&&typeof n=="function"&&n(c),r.options.errorCallback(c)}function o(c){var d=r.options.imageTexts.sizeUnits.split(",");return c.replace("#image_name#",e.name).replace("#image_size#",yd(e.size,d)).replace("#image_max_size#",yd(r.options.imageMaxSize,d))}if(e.size>this.options.imageMaxSize){a(o(this.options.errorMessages.fileTooLarge));return}var l=new FormData;l.append("image",e),r.options.imageCSRFToken&&!r.options.imageCSRFHeader&&l.append(r.options.imageCSRFName,r.options.imageCSRFToken);var u=new XMLHttpRequest;u.upload.onprogress=function(c){if(c.lengthComputable){var d=""+Math.round(c.loaded*100/c.total);r.updateStatusBar("upload-image",r.options.imageTexts.sbProgress.replace("#file_name#",e.name).replace("#progress#",d))}},u.open("POST",this.options.imageUploadEndpoint),r.options.imageCSRFToken&&r.options.imageCSRFHeader&&u.setRequestHeader(r.options.imageCSRFName,r.options.imageCSRFToken),u.onload=function(){try{var c=JSON.parse(this.responseText)}catch{console.error("EasyMDE: The server did not return a valid json."),a(o(r.options.errorMessages.importError));return}this.status===200&&c&&!c.error&&c.data&&c.data.filePath?t((r.options.imagePathAbsolute?"":window.location.origin+"/")+c.data.filePath):c.error&&c.error in r.options.errorMessages?a(o(r.options.errorMessages[c.error])):c.error?a(o(c.error)):(console.error("EasyMDE: Received an unexpected response after uploading the image."+this.status+" ("+this.statusText+")"),a(o(r.options.errorMessages.importError)))},u.onerror=function(c){console.error("EasyMDE: An unexpected error occurred when trying to upload the image."+c.target.status+" ("+c.target.statusText+")"),a(r.options.errorMessages.importError)},u.send(l)};It.prototype.uploadImageUsingCustomFunction=function(e,t){var n=this;function r(l){_R(n,l)}function a(l){var u=o(l);n.updateStatusBar("upload-image",u),setTimeout(function(){n.updateStatusBar("upload-image",n.options.imageTexts.sbInit)},1e4),n.options.errorCallback(u)}function o(l){var u=n.options.imageTexts.sizeUnits.split(",");return l.replace("#image_name#",t.name).replace("#image_size#",yd(t.size,u)).replace("#image_max_size#",yd(n.options.imageMaxSize,u))}e.apply(this,[t,r,a])};It.prototype.setPreviewMaxHeight=function(){var e=this.codemirror,t=e.getWrapperElement(),n=t.nextSibling,r=parseInt(window.getComputedStyle(t).paddingTop),a=parseInt(window.getComputedStyle(t).borderTopWidth),o=parseInt(this.options.maxHeight),l=o+r*2+a*2,u=l.toString()+"px";n.style.height=u};It.prototype.createSideBySide=function(){var e=this.codemirror,t=e.getWrapperElement(),n=t.nextSibling;if(!n||!n.classList.contains("editor-preview-side")){if(n=document.createElement("div"),n.className="editor-preview-side",this.options.previewClass)if(Array.isArray(this.options.previewClass))for(var r=0;r<this.options.previewClass.length;r++)n.classList.add(this.options.previewClass[r]);else typeof this.options.previewClass=="string"&&n.classList.add(this.options.previewClass);t.parentNode.insertBefore(n,t.nextSibling)}if(typeof this.options.maxHeight<"u"&&this.setPreviewMaxHeight(),this.options.syncSideBySidePreviewScroll===!1)return n;var a=!1,o=!1;return e.on("scroll",function(l){if(a){a=!1;return}o=!0;var u=l.getScrollInfo().height-l.getScrollInfo().clientHeight,c=parseFloat(l.getScrollInfo().top)/u,d=(n.scrollHeight-n.clientHeight)*c;n.scrollTop=d}),n.onscroll=function(){if(o){o=!1;return}a=!0;var l=n.scrollHeight-n.clientHeight,u=parseFloat(n.scrollTop)/l,c=(e.getScrollInfo().height-e.getScrollInfo().clientHeight)*u;e.scrollTo(0,c)},n};It.prototype.createToolbar=function(e){if(e=e||this.options.toolbar,!(!e||e.length===0)){var t;for(t=0;t<e.length;t++)Ms[e[t]]!=null&&(e[t]=Ms[e[t]]);var n=document.createElement("div");n.className="editor-toolbar",n.setAttribute("role","toolbar");var r=this,a={};for(r.toolbar=e,t=0;t<e.length;t++)if(!(e[t].name=="guide"&&r.options.toolbarGuideIcon===!1)&&!(r.options.hideIcons&&r.options.hideIcons.indexOf(e[t].name)!=-1)&&!((e[t].name=="fullscreen"||e[t].name=="side-by-side")&&wh())){if(e[t]==="|"){for(var o=!1,l=t+1;l<e.length;l++)e[l]!=="|"&&(!r.options.hideIcons||r.options.hideIcons.indexOf(e[l].name)==-1)&&(o=!0);if(!o)continue}(function(d){var S;if(d==="|"?S=KB():d.children?S=zB(d,r.options.toolbarTips,r.options.shortcuts,r):S=fd(d,!0,r.options.toolbarTips,r.options.shortcuts,"button",r),a[d.name||d]=S,n.appendChild(S),d.name==="upload-image"){var _=document.createElement("input");_.className="imageInput",_.type="file",_.multiple=!0,_.name="image",_.accept=r.options.imageAccept,_.style.display="none",_.style.opacity=0,n.appendChild(_)}})(e[t])}r.toolbar_div=n,r.toolbarElements=a;var u=this.codemirror;u.on("cursorActivity",function(){var d=ds(u);for(var S in a)(function(_){var E=a[_];d[_]?E.classList.add("active"):_!="fullscreen"&&_!="side-by-side"&&E.classList.remove("active")})(S)});var c=u.getWrapperElement();return c.parentNode.insertBefore(n,c),n}};It.prototype.createStatusbar=function(e){e=e||this.options.status;var t=this.options,n=this.codemirror;if(!(!e||e.length===0)){var r=[],a,o,l,u;for(a=0;a<e.length;a++)if(o=void 0,l=void 0,u=void 0,typeof e[a]=="object")r.push({className:e[a].className,defaultValue:e[a].defaultValue,onUpdate:e[a].onUpdate,onActivity:e[a].onActivity});else{var c=e[a];c==="words"?(u=function(T){T.innerHTML=uC(n.getValue())},o=function(T){T.innerHTML=uC(n.getValue())}):c==="lines"?(u=function(T){T.innerHTML=n.lineCount()},o=function(T){T.innerHTML=n.lineCount()}):c==="cursor"?(u=function(T){T.innerHTML="1:1"},l=function(T){var y=n.getCursor(),M=y.line+1,v=y.ch+1;T.innerHTML=M+":"+v}):c==="autosave"?u=function(T){t.autosave!=null&&t.autosave.enabled===!0&&T.setAttribute("id","autosaved")}:c==="upload-image"&&(u=function(T){T.innerHTML=t.imageTexts.sbInit}),r.push({className:c,defaultValue:u,onUpdate:o,onActivity:l})}var d=document.createElement("div");for(d.className="editor-statusbar",a=0;a<r.length;a++){var S=r[a],_=document.createElement("span");_.className=S.className,typeof S.defaultValue=="function"&&S.defaultValue(_),typeof S.onUpdate=="function"&&this.codemirror.on("update",function(T,y){return function(){y.onUpdate(T)}}(_,S)),typeof S.onActivity=="function"&&this.codemirror.on("cursorActivity",function(T,y){return function(){y.onActivity(T)}}(_,S)),d.appendChild(_)}var E=this.codemirror.getWrapperElement();return E.parentNode.insertBefore(d,E.nextSibling),d}};It.prototype.value=function(e){var t=this.codemirror;if(e===void 0)return t.getValue();if(t.getDoc().setValue(e),this.isPreviewActive()){var n=t.getWrapperElement(),r=n.lastChild,a=this.options.previewRender(e,r);a!==null&&(r.innerHTML=a)}return this};It.toggleBold=jd;It.toggleItalic=Xd;It.toggleStrikethrough=Zd;It.toggleBlockquote=ef;It.toggleHeadingSmaller=$u;It.toggleHeadingBigger=tf;It.toggleHeading1=nf;It.toggleHeading2=rf;It.toggleHeading3=af;It.toggleHeading4=FE;It.toggleHeading5=BE;It.toggleHeading6=UE;It.toggleCodeBlock=Jd;It.toggleUnorderedList=of;It.toggleOrderedList=sf;It.cleanBlock=lf;It.drawLink=uf;It.drawImage=cf;It.drawUploadedImage=GE;It.drawTable=df;It.drawHorizontalRule=ff;It.undo=pf;It.redo=_f;It.togglePreview=mf;It.toggleSideBySide=Zl;It.toggleFullScreen=zs;It.prototype.toggleBold=function(){jd(this)};It.prototype.toggleItalic=function(){Xd(this)};It.prototype.toggleStrikethrough=function(){Zd(this)};It.prototype.toggleBlockquote=function(){ef(this)};It.prototype.toggleHeadingSmaller=function(){$u(this)};It.prototype.toggleHeadingBigger=function(){tf(this)};It.prototype.toggleHeading1=function(){nf(this)};It.prototype.toggleHeading2=function(){rf(this)};It.prototype.toggleHeading3=function(){af(this)};It.prototype.toggleHeading4=function(){FE(this)};It.prototype.toggleHeading5=function(){BE(this)};It.prototype.toggleHeading6=function(){UE(this)};It.prototype.toggleCodeBlock=function(){Jd(this)};It.prototype.toggleUnorderedList=function(){of(this)};It.prototype.toggleOrderedList=function(){sf(this)};It.prototype.cleanBlock=function(){lf(this)};It.prototype.drawLink=function(){uf(this)};It.prototype.drawImage=function(){cf(this)};It.prototype.drawUploadedImage=function(){GE(this)};It.prototype.drawTable=function(){df(this)};It.prototype.drawHorizontalRule=function(){ff(this)};It.prototype.undo=function(){pf(this)};It.prototype.redo=function(){_f(this)};It.prototype.togglePreview=function(){mf(this)};It.prototype.toggleSideBySide=function(){Zl(this)};It.prototype.toggleFullScreen=function(){zs(this)};It.prototype.isPreviewActive=function(){var e=this.codemirror,t=e.getWrapperElement(),n=t.lastChild;return n.classList.contains("editor-preview-active")};It.prototype.isSideBySideActive=function(){var e=this.codemirror,t=e.getWrapperElement(),n=t.nextSibling;return n.classList.contains("editor-preview-active-side")};It.prototype.isFullscreenActive=function(){var e=this.codemirror;return e.getOption("fullScreen")};It.prototype.getState=function(){var e=this.codemirror;return ds(e)};It.prototype.toTextArea=function(){var e=this.codemirror,t=e.getWrapperElement(),n=t.parentNode;n&&(this.gui.toolbar&&n.removeChild(this.gui.toolbar),this.gui.statusbar&&n.removeChild(this.gui.statusbar),this.gui.sideBySide&&n.removeChild(this.gui.sideBySide)),n.parentNode.insertBefore(t,n),n.remove(),e.toTextArea(),this.autosaveTimeoutId&&(clearTimeout(this.autosaveTimeoutId),this.autosaveTimeoutId=void 0,this.clearAutosavedValue())};var nU=It;function Jl(e,t){const n=Object.create(null),r=e.split(",");for(let a=0;a<r.length;a++)n[r[a]]=!0;return t?a=>!!n[a.toLowerCase()]:a=>!!n[a]}const yn={},Ol=[],vi=()=>{},rU=()=>!1,iU=/^on[^a-z]/,Co=e=>iU.test(e),YE=e=>e.startsWith("onUpdate:"),sn=Object.assign,WE=(e,t)=>{const n=e.indexOf(t);n>-1&&e.splice(n,1)},aU=Object.prototype.hasOwnProperty,_n=(e,t)=>aU.call(e,t),Rt=Array.isArray,Rl=e=>eu(e)==="[object Map]",Js=e=>eu(e)==="[object Set]",cC=e=>eu(e)==="[object Date]",oU=e=>eu(e)==="[object RegExp]",Ft=e=>typeof e=="function",xn=e=>typeof e=="string",Ul=e=>typeof e=="symbol",ln=e=>e!==null&&typeof e=="object",gf=e=>(ln(e)||Ft(e))&&Ft(e.then)&&Ft(e.catch),ER=Object.prototype.toString,eu=e=>ER.call(e),sU=e=>eu(e).slice(8,-1),Cd=e=>eu(e)==="[object Object]",VE=e=>xn(e)&&e!=="NaN"&&e[0]!=="-"&&""+parseInt(e,10)===e,Nl=Jl(",key,ref,ref_for,ref_key,onVnodeBeforeMount,onVnodeMounted,onVnodeBeforeUpdate,onVnodeUpdated,onVnodeBeforeUnmount,onVnodeUnmounted"),hf=e=>{const t=Object.create(null);return n=>t[n]||(t[n]=e(n))},lU=/-(\w)/g,ni=hf(e=>e.replace(lU,(t,n)=>n?n.toUpperCase():"")),uU=/\B([A-Z])/g,ei=hf(e=>e.replace(uU,"-$1").toLowerCase()),gc=hf(e=>e.charAt(0).toUpperCase()+e.slice(1)),Il=hf(e=>e?`on${gc(e)}`:""),os=(e,t)=>!Object.is(e,t),Jo=(e,t)=>{for(let n=0;n<e.length;n++)e[n](t)},Ad=(e,t,n)=>{Object.defineProperty(e,t,{configurable:!0,enumerable:!1,value:n})},Qu=e=>{const t=parseFloat(e);return isNaN(t)?e:t},Od=e=>{const t=xn(e)?Number(e):NaN;return isNaN(t)?e:t};let dC;const Lh=()=>dC||(dC=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:typeof global<"u"?global:{}),cU="Infinity,undefined,NaN,isFinite,isNaN,parseFloat,parseInt,decodeURI,decodeURIComponent,encodeURI,encodeURIComponent,Math,Number,Date,Array,Object,Boolean,String,RegExp,Map,Set,JSON,Intl,BigInt,console",dU=Jl(cU);function tu(e){if(Rt(e)){const t={};for(let n=0;n<e.length;n++){const r=e[n],a=xn(r)?mU(r):tu(r);if(a)for(const o in a)t[o]=a[o]}return t}else if(xn(e)||ln(e))return e}const fU=/;(?![^(]*\))/g,pU=/:([^]+)/,_U=/\/\*[^]*?\*\//g;function mU(e){const t={};return e.replace(_U,"").split(fU).forEach(n=>{if(n){const r=n.split(pU);r.length>1&&(t[r[0].trim()]=r[1].trim())}}),t}function Va(e){let t="";if(xn(e))t=e;else if(Rt(e))for(let n=0;n<e.length;n++){const r=Va(e[n]);r&&(t+=r+" ")}else if(ln(e))for(const n in e)e[n]&&(t+=n+" ");return t.trim()}function gU(e){if(!e)return null;let{class:t,style:n}=e;return t&&!xn(t)&&(e.class=Va(t)),n&&(e.style=tu(n)),e}const hU="itemscope,allowfullscreen,formnovalidate,ismap,nomodule,novalidate,readonly",SR=Jl(hU);function bR(e){return!!e||e===""}function EU(e,t){if(e.length!==t.length)return!1;let n=!0;for(let r=0;n&&r<e.length;r++)n=To(e[r],t[r]);return n}function To(e,t){if(e===t)return!0;let n=cC(e),r=cC(t);if(n||r)return n&&r?e.getTime()===t.getTime():!1;if(n=Ul(e),r=Ul(t),n||r)return e===t;if(n=Rt(e),r=Rt(t),n||r)return n&&r?EU(e,t):!1;if(n=ln(e),r=ln(t),n||r){if(!n||!r)return!1;const a=Object.keys(e).length,o=Object.keys(t).length;if(a!==o)return!1;for(const l in e){const u=e.hasOwnProperty(l),c=t.hasOwnProperty(l);if(u&&!c||!u&&c||!To(e[l],t[l]))return!1}}return String(e)===String(t)}function hc(e,t){return e.findIndex(n=>To(n,t))}const Rd=e=>xn(e)?e:e==null?"":Rt(e)||ln(e)&&(e.toString===ER||!Ft(e.toString))?JSON.stringify(e,vR,2):String(e),vR=(e,t)=>t&&t.__v_isRef?vR(e,t.value):Rl(t)?{[`Map(${t.size})`]:[...t.entries()].reduce((n,[r,a])=>(n[`${r} =>`]=a,n),{})}:Js(t)?{[`Set(${t.size})`]:[...t.values()]}:ln(t)&&!Rt(t)&&!Cd(t)?String(t):t;let Mi;class zE{constructor(t=!1){this.detached=t,this._active=!0,this.effects=[],this.cleanups=[],this.parent=Mi,!t&&Mi&&(this.index=(Mi.scopes||(Mi.scopes=[])).push(this)-1)}get active(){return this._active}run(t){if(this._active){const n=Mi;try{return Mi=this,t()}finally{Mi=n}}}on(){Mi=this}off(){Mi=this.parent}stop(t){if(this._active){let n,r;for(n=0,r=this.effects.length;n<r;n++)this.effects[n].stop();for(n=0,r=this.cleanups.length;n<r;n++)this.cleanups[n]();if(this.scopes)for(n=0,r=this.scopes.length;n<r;n++)this.scopes[n].stop(!0);if(!this.detached&&this.parent&&!t){const a=this.parent.scopes.pop();a&&a!==this&&(this.parent.scopes[this.index]=a,a.index=this.index)}this.parent=void 0,this._active=!1}}}function SU(e){return new zE(e)}function TR(e,t=Mi){t&&t.active&&t.effects.push(e)}function yR(){return Mi}function bU(e){Mi&&Mi.cleanups.push(e)}const KE=e=>{const t=new Set(e);return t.w=0,t.n=0,t},CR=e=>(e.w&ss)>0,AR=e=>(e.n&ss)>0,vU=({deps:e})=>{if(e.length)for(let t=0;t<e.length;t++)e[t].w|=ss},TU=e=>{const{deps:t}=e;if(t.length){let n=0;for(let r=0;r<t.length;r++){const a=t[r];CR(a)&&!AR(a)?a.delete(e):t[n++]=a,a.w&=~ss,a.n&=~ss}t.length=n}},Nd=new WeakMap;let Du=0,ss=1;const Mh=30;let Sa;const ks=Symbol(""),kh=Symbol("");class Gl{constructor(t,n=null,r){this.fn=t,this.scheduler=n,this.active=!0,this.deps=[],this.parent=void 0,TR(this,r)}run(){if(!this.active)return this.fn();let t=Sa,n=es;for(;t;){if(t===this)return;t=t.parent}try{return this.parent=Sa,Sa=this,es=!0,ss=1<<++Du,Du<=Mh?vU(this):fC(this),this.fn()}finally{Du<=Mh&&TU(this),ss=1<<--Du,Sa=this.parent,es=n,this.parent=void 0,this.deferStop&&this.stop()}}stop(){Sa===this?this.deferStop=!0:this.active&&(fC(this),this.onStop&&this.onStop(),this.active=!1)}}function fC(e){const{deps:t}=e;if(t.length){for(let n=0;n<t.length;n++)t[n].delete(e);t.length=0}}function yU(e,t){e.effect instanceof Gl&&(e=e.effect.fn);const n=new Gl(e);t&&(sn(n,t),t.scope&&TR(n,t.scope)),(!t||!t.lazy)&&n.run();const r=n.run.bind(n);return r.effect=n,r}function CU(e){e.effect.stop()}let es=!0;const OR=[];function nu(){OR.push(es),es=!1}function ru(){const e=OR.pop();es=e===void 0?!0:e}function ri(e,t,n){if(es&&Sa){let r=Nd.get(e);r||Nd.set(e,r=new Map);let a=r.get(n);a||r.set(n,a=KE()),RR(a)}}function RR(e,t){let n=!1;Du<=Mh?AR(e)||(e.n|=ss,n=!CR(e)):n=!e.has(Sa),n&&(e.add(Sa),Sa.deps.push(e))}function qa(e,t,n,r,a,o){const l=Nd.get(e);if(!l)return;let u=[];if(t==="clear")u=[...l.values()];else if(n==="length"&&Rt(e)){const c=Number(r);l.forEach((d,S)=>{(S==="length"||!Ul(S)&&S>=c)&&u.push(d)})}else switch(n!==void 0&&u.push(l.get(n)),t){case"add":Rt(e)?VE(n)&&u.push(l.get("length")):(u.push(l.get(ks)),Rl(e)&&u.push(l.get(kh)));break;case"delete":Rt(e)||(u.push(l.get(ks)),Rl(e)&&u.push(l.get(kh)));break;case"set":Rl(e)&&u.push(l.get(ks));break}if(u.length===1)u[0]&&Ph(u[0]);else{const c=[];for(const d of u)d&&c.push(...d);Ph(KE(c))}}function Ph(e,t){const n=Rt(e)?e:[...e];for(const r of n)r.computed&&pC(r);for(const r of n)r.computed||pC(r)}function pC(e,t){(e!==Sa||e.allowRecurse)&&(e.scheduler?e.scheduler():e.run())}function AU(e,t){var n;return(n=Nd.get(e))==null?void 0:n.get(t)}const OU=Jl("__proto__,__v_isRef,__isVue"),NR=new Set(Object.getOwnPropertyNames(Symbol).filter(e=>e!=="arguments"&&e!=="caller").map(e=>Symbol[e]).filter(Ul)),_C=RU();function RU(){const e={};return["includes","indexOf","lastIndexOf"].forEach(t=>{e[t]=function(...n){const r=pn(this);for(let o=0,l=this.length;o<l;o++)ri(r,"get",o+"");const a=r[t](...n);return a===-1||a===!1?r[t](...n.map(pn)):a}}),["push","pop","shift","unshift","splice"].forEach(t=>{e[t]=function(...n){nu();const r=pn(this)[t].apply(this,n);return ru(),r}}),e}function NU(e){const t=pn(this);return ri(t,"has",e),t.hasOwnProperty(e)}class IR{constructor(t=!1,n=!1){this._isReadonly=t,this._shallow=n}get(t,n,r){const a=this._isReadonly,o=this._shallow;if(n==="__v_isReactive")return!a;if(n==="__v_isReadonly")return a;if(n==="__v_isShallow")return o;if(n==="__v_raw"&&r===(a?o?kR:MR:o?LR:wR).get(t))return t;const l=Rt(t);if(!a){if(l&&_n(_C,n))return Reflect.get(_C,n,r);if(n==="hasOwnProperty")return NU}const u=Reflect.get(t,n,r);return(Ul(n)?NR.has(n):OU(n))||(a||ri(t,"get",n),o)?u:sr(u)?l&&VE(n)?u:u.value:ln(u)?a?QE(u):ls(u):u}}class DR extends IR{constructor(t=!1){super(!1,t)}set(t,n,r,a){let o=t[n];if($s(o)&&sr(o)&&!sr(r))return!1;if(!this._shallow&&(!ju(r)&&!$s(r)&&(o=pn(o),r=pn(r)),!Rt(t)&&sr(o)&&!sr(r)))return o.value=r,!0;const l=Rt(t)&&VE(n)?Number(n)<t.length:_n(t,n),u=Reflect.set(t,n,r,a);return t===pn(a)&&(l?os(r,o)&&qa(t,"set",n,r):qa(t,"add",n,r)),u}deleteProperty(t,n){const r=_n(t,n);t[n];const a=Reflect.deleteProperty(t,n);return a&&r&&qa(t,"delete",n,void 0),a}has(t,n){const r=Reflect.has(t,n);return(!Ul(n)||!NR.has(n))&&ri(t,"has",n),r}ownKeys(t){return ri(t,"iterate",Rt(t)?"length":ks),Reflect.ownKeys(t)}}class xR extends IR{constructor(t=!1){super(!0,t)}set(t,n){return!0}deleteProperty(t,n){return!0}}const IU=new DR,DU=new xR,xU=new DR(!0),wU=new xR(!0),$E=e=>e,Ef=e=>Reflect.getPrototypeOf(e);function Xc(e,t,n=!1,r=!1){e=e.__v_raw;const a=pn(e),o=pn(t);n||(os(t,o)&&ri(a,"get",t),ri(a,"get",o));const{has:l}=Ef(a),u=r?$E:n?ZE:Xu;if(l.call(a,t))return u(e.get(t));if(l.call(a,o))return u(e.get(o));e!==a&&e.get(t)}function Zc(e,t=!1){const n=this.__v_raw,r=pn(n),a=pn(e);return t||(os(e,a)&&ri(r,"has",e),ri(r,"has",a)),e===a?n.has(e):n.has(e)||n.has(a)}function Jc(e,t=!1){return e=e.__v_raw,!t&&ri(pn(e),"iterate",ks),Reflect.get(e,"size",e)}function mC(e){e=pn(e);const t=pn(this);return Ef(t).has.call(t,e)||(t.add(e),qa(t,"add",e,e)),this}function gC(e,t){t=pn(t);const n=pn(this),{has:r,get:a}=Ef(n);let o=r.call(n,e);o||(e=pn(e),o=r.call(n,e));const l=a.call(n,e);return n.set(e,t),o?os(t,l)&&qa(n,"set",e,t):qa(n,"add",e,t),this}function hC(e){const t=pn(this),{has:n,get:r}=Ef(t);let a=n.call(t,e);a||(e=pn(e),a=n.call(t,e)),r&&r.call(t,e);const o=t.delete(e);return a&&qa(t,"delete",e,void 0),o}function EC(){const e=pn(this),t=e.size!==0,n=e.clear();return t&&qa(e,"clear",void 0,void 0),n}function ed(e,t){return function(r,a){const o=this,l=o.__v_raw,u=pn(l),c=t?$E:e?ZE:Xu;return!e&&ri(u,"iterate",ks),l.forEach((d,S)=>r.call(a,c(d),c(S),o))}}function td(e,t,n){return function(...r){const a=this.__v_raw,o=pn(a),l=Rl(o),u=e==="entries"||e===Symbol.iterator&&l,c=e==="keys"&&l,d=a[e](...r),S=n?$E:t?ZE:Xu;return!t&&ri(o,"iterate",c?kh:ks),{next(){const{value:_,done:E}=d.next();return E?{value:_,done:E}:{value:u?[S(_[0]),S(_[1])]:S(_),done:E}},[Symbol.iterator](){return this}}}}function Yo(e){return function(...t){return e==="delete"?!1:this}}function LU(){const e={get(o){return Xc(this,o)},get size(){return Jc(this)},has:Zc,add:mC,set:gC,delete:hC,clear:EC,forEach:ed(!1,!1)},t={get(o){return Xc(this,o,!1,!0)},get size(){return Jc(this)},has:Zc,add:mC,set:gC,delete:hC,clear:EC,forEach:ed(!1,!0)},n={get(o){return Xc(this,o,!0)},get size(){return Jc(this,!0)},has(o){return Zc.call(this,o,!0)},add:Yo("add"),set:Yo("set"),delete:Yo("delete"),clear:Yo("clear"),forEach:ed(!0,!1)},r={get(o){return Xc(this,o,!0,!0)},get size(){return Jc(this,!0)},has(o){return Zc.call(this,o,!0)},add:Yo("add"),set:Yo("set"),delete:Yo("delete"),clear:Yo("clear"),forEach:ed(!0,!0)};return["keys","values","entries",Symbol.iterator].forEach(o=>{e[o]=td(o,!1,!1),n[o]=td(o,!0,!1),t[o]=td(o,!1,!0),r[o]=td(o,!0,!0)}),[e,n,t,r]}const[MU,kU,PU,FU]=LU();function Sf(e,t){const n=t?e?FU:PU:e?kU:MU;return(r,a,o)=>a==="__v_isReactive"?!e:a==="__v_isReadonly"?e:a==="__v_raw"?r:Reflect.get(_n(n,a)&&a in r?n:r,a,o)}const BU={get:Sf(!1,!1)},UU={get:Sf(!1,!0)},GU={get:Sf(!0,!1)},HU={get:Sf(!0,!0)},wR=new WeakMap,LR=new WeakMap,MR=new WeakMap,kR=new WeakMap;function qU(e){switch(e){case"Object":case"Array":return 1;case"Map":case"Set":case"WeakMap":case"WeakSet":return 2;default:return 0}}function YU(e){return e.__v_skip||!Object.isExtensible(e)?0:qU(sU(e))}function ls(e){return $s(e)?e:bf(e,!1,IU,BU,wR)}function PR(e){return bf(e,!1,xU,UU,LR)}function QE(e){return bf(e,!0,DU,GU,MR)}function WU(e){return bf(e,!0,wU,HU,kR)}function bf(e,t,n,r,a){if(!ln(e)||e.__v_raw&&!(t&&e.__v_isReactive))return e;const o=a.get(e);if(o)return o;const l=YU(e);if(l===0)return e;const u=new Proxy(e,l===2?r:n);return a.set(e,u),u}function So(e){return $s(e)?So(e.__v_raw):!!(e&&e.__v_isReactive)}function $s(e){return!!(e&&e.__v_isReadonly)}function ju(e){return!!(e&&e.__v_isShallow)}function jE(e){return So(e)||$s(e)}function pn(e){const t=e&&e.__v_raw;return t?pn(t):e}function XE(e){return Ad(e,"__v_skip",!0),e}const Xu=e=>ln(e)?ls(e):e,ZE=e=>ln(e)?QE(e):e;function JE(e){es&&Sa&&(e=pn(e),RR(e.dep||(e.dep=KE())))}function vf(e,t){e=pn(e);const n=e.dep;n&&Ph(n)}function sr(e){return!!(e&&e.__v_isRef===!0)}function Dl(e){return FR(e,!1)}function VU(e){return FR(e,!0)}function FR(e,t){return sr(e)?e:new zU(e,t)}class zU{constructor(t,n){this.__v_isShallow=n,this.dep=void 0,this.__v_isRef=!0,this._rawValue=n?t:pn(t),this._value=n?t:Xu(t)}get value(){return JE(this),this._value}set value(t){const n=this.__v_isShallow||ju(t)||$s(t);t=n?t:pn(t),os(t,this._rawValue)&&(this._rawValue=t,this._value=n?t:Xu(t),vf(this))}}function KU(e){vf(e)}function eS(e){return sr(e)?e.value:e}function $U(e){return Ft(e)?e():eS(e)}const QU={get:(e,t,n)=>eS(Reflect.get(e,t,n)),set:(e,t,n,r)=>{const a=e[t];return sr(a)&&!sr(n)?(a.value=n,!0):Reflect.set(e,t,n,r)}};function tS(e){return So(e)?e:new Proxy(e,QU)}class jU{constructor(t){this.dep=void 0,this.__v_isRef=!0;const{get:n,set:r}=t(()=>JE(this),()=>vf(this));this._get=n,this._set=r}get value(){return this._get()}set value(t){this._set(t)}}function XU(e){return new jU(e)}function ZU(e){const t=Rt(e)?new Array(e.length):{};for(const n in e)t[n]=BR(e,n);return t}class JU{constructor(t,n,r){this._object=t,this._key=n,this._defaultValue=r,this.__v_isRef=!0}get value(){const t=this._object[this._key];return t===void 0?this._defaultValue:t}set value(t){this._object[this._key]=t}get dep(){return AU(pn(this._object),this._key)}}class e3{constructor(t){this._getter=t,this.__v_isRef=!0,this.__v_isReadonly=!0}get value(){return this._getter()}}function t3(e,t,n){return sr(e)?e:Ft(e)?new e3(e):ln(e)&&arguments.length>1?BR(e,t,n):Dl(e)}function BR(e,t,n){const r=e[t];return sr(r)?r:new JU(e,t,n)}class n3{constructor(t,n,r,a){this._setter=n,this.dep=void 0,this.__v_isRef=!0,this.__v_isReadonly=!1,this._dirty=!0,this.effect=new Gl(t,()=>{this._dirty||(this._dirty=!0,vf(this))}),this.effect.computed=this,this.effect.active=this._cacheable=!a,this.__v_isReadonly=r}get value(){const t=pn(this);return JE(t),(t._dirty||!t._cacheable)&&(t._dirty=!1,t._value=t.effect.run()),t._value}set value(t){this._setter(t)}}function r3(e,t,n=!1){let r,a;const o=Ft(e);return o?(r=e,a=vi):(r=e.get,a=e.set),new n3(r,a,o||!a,n)}function i3(e,...t){}function a3(e,t){}function Ya(e,t,n,r){let a;try{a=r?e(...r):e()}catch(o){el(o,t,n)}return a}function Ti(e,t,n,r){if(Ft(e)){const o=Ya(e,t,n,r);return o&&gf(o)&&o.catch(l=>{el(l,t,n)}),o}const a=[];for(let o=0;o<e.length;o++)a.push(Ti(e[o],t,n,r));return a}function el(e,t,n,r=!0){const a=t?t.vnode:null;if(t){let o=t.parent;const l=t.proxy,u=n;for(;o;){const d=o.ec;if(d){for(let S=0;S<d.length;S++)if(d[S](e,l,u)===!1)return}o=o.parent}const c=t.appContext.config.errorHandler;if(c){Ya(c,null,10,[e,l,u]);return}}o3(e,n,a,r)}function o3(e,t,n,r=!0){console.error(e)}let Zu=!1,Fh=!1;const kr=[];let Ua=0;const xl=[];let ho=null,As=0;const UR=Promise.resolve();let nS=null;function Ec(e){const t=nS||UR;return e?t.then(this?e.bind(this):e):t}function s3(e){let t=Ua+1,n=kr.length;for(;t<n;){const r=t+n>>>1,a=kr[r],o=Ju(a);o<e||o===e&&a.pre?t=r+1:n=r}return t}function Tf(e){(!kr.length||!kr.includes(e,Zu&&e.allowRecurse?Ua+1:Ua))&&(e.id==null?kr.push(e):kr.splice(s3(e.id),0,e),GR())}function GR(){!Zu&&!Fh&&(Fh=!0,nS=UR.then(HR))}function l3(e){const t=kr.indexOf(e);t>Ua&&kr.splice(t,1)}function Id(e){Rt(e)?xl.push(...e):(!ho||!ho.includes(e,e.allowRecurse?As+1:As))&&xl.push(e),GR()}function SC(e,t=Zu?Ua+1:0){for(;t<kr.length;t++){const n=kr[t];n&&n.pre&&(kr.splice(t,1),t--,n())}}function Dd(e){if(xl.length){const t=[...new Set(xl)];if(xl.length=0,ho){ho.push(...t);return}for(ho=t,ho.sort((n,r)=>Ju(n)-Ju(r)),As=0;As<ho.length;As++)ho[As]();ho=null,As=0}}const Ju=e=>e.id==null?1/0:e.id,u3=(e,t)=>{const n=Ju(e)-Ju(t);if(n===0){if(e.pre&&!t.pre)return-1;if(t.pre&&!e.pre)return 1}return n};function HR(e){Fh=!1,Zu=!0,kr.sort(u3);const t=vi;try{for(Ua=0;Ua<kr.length;Ua++){const n=kr[Ua];n&&n.active!==!1&&Ya(n,null,14)}}finally{Ua=0,kr.length=0,Dd(),Zu=!1,nS=null,(kr.length||xl.length)&&HR()}}let yl,nd=[];function qR(e,t){var n,r;yl=e,yl?(yl.enabled=!0,nd.forEach(({event:a,args:o})=>yl.emit(a,...o)),nd=[]):typeof window<"u"&&window.HTMLElement&&!((r=(n=window.navigator)==null?void 0:n.userAgent)!=null&&r.includes("jsdom"))?((t.__VUE_DEVTOOLS_HOOK_REPLAY__=t.__VUE_DEVTOOLS_HOOK_REPLAY__||[]).push(o=>{qR(o,t)}),setTimeout(()=>{yl||(t.__VUE_DEVTOOLS_HOOK_REPLAY__=null,nd=[])},3e3)):nd=[]}function c3(e,t,...n){}const rS={MODE:2};function d3(e){sn(rS,e)}function bC(e,t){const n=t&&t.type.compatConfig;return n&&e in n?n[e]:rS[e]}function Sn(e,t,n=!1){if(!n&&t&&t.type.__isBuiltIn)return!1;const r=bC("MODE",t)||2,a=bC(e,t);return(Ft(r)?r(t&&t.type):r)===2?a!==!1:a===!0||a==="suppress-warning"}function Ir(e,t,...n){if(!Sn(e,t))throw new Error(`${e} compat has been disabled.`)}function yo(e,t,...n){return Sn(e,t)}function yf(e,t,...n){return Sn(e,t)}const Bh=new WeakMap;function iS(e){let t=Bh.get(e);return t||Bh.set(e,t=Object.create(null)),t}function aS(e,t,n){if(Rt(t))t.forEach(r=>aS(e,r,n));else{t.startsWith("hook:")?Ir("INSTANCE_EVENT_HOOKS",e,t):Ir("INSTANCE_EVENT_EMITTER",e);const r=iS(e);(r[t]||(r[t]=[])).push(n)}return e.proxy}function f3(e,t,n){const r=(...a)=>{oS(e,t,r),n.call(e.proxy,...a)};return r.fn=n,aS(e,t,r),e.proxy}function oS(e,t,n){Ir("INSTANCE_EVENT_EMITTER",e);const r=e.proxy;if(!t)return Bh.set(e,Object.create(null)),r;if(Rt(t))return t.forEach(l=>oS(e,l,n)),r;const a=iS(e),o=a[t];return o?n?(a[t]=o.filter(l=>!(l===n||l.fn===n)),r):(a[t]=void 0,r):r}function p3(e,t,n){const r=iS(e)[t];return r&&Ti(r.map(a=>a.bind(e.proxy)),e,6,n),e.proxy}const Cf="onModelCompat:";function _3(e){const{type:t,shapeFlag:n,props:r,dynamicProps:a}=e,o=t;if(n&6&&r&&"modelValue"in r){if(!Sn("COMPONENT_V_MODEL",{type:t}))return;const l=o.model||{};YR(l,o.mixins);const{prop:u="value",event:c="input"}=l;u!=="modelValue"&&(r[u]=r.modelValue,delete r.modelValue),a&&(a[a.indexOf("modelValue")]=u),r[Cf+c]=r["onUpdate:modelValue"],delete r["onUpdate:modelValue"]}}function YR(e,t){t&&t.forEach(n=>{n.model&&sn(e,n.model),n.mixins&&YR(e,n.mixins)})}function m3(e,t,n){if(!Sn("COMPONENT_V_MODEL",e))return;const r=e.vnode.props,a=r&&r[Cf+t];a&&Ya(a,e,6,n)}function g3(e,t,...n){if(e.isUnmounted)return;const r=e.vnode.props||yn;let a=n;const o=t.startsWith("update:"),l=o&&t.slice(7);if(l&&l in r){const S=`${l==="modelValue"?"model":l}Modifiers`,{number:_,trim:E}=r[S]||yn;E&&(a=n.map(T=>xn(T)?T.trim():T)),_&&(a=n.map(Qu))}let u,c=r[u=Il(t)]||r[u=Il(ni(t))];!c&&o&&(c=r[u=Il(ei(t))]),c&&Ti(c,e,6,a);const d=r[u+"Once"];if(d){if(!e.emitted)e.emitted={};else if(e.emitted[u])return;e.emitted[u]=!0,Ti(d,e,6,a)}return m3(e,t,a),p3(e,t,a)}function WR(e,t,n=!1){const r=t.emitsCache,a=r.get(e);if(a!==void 0)return a;const o=e.emits;let l={},u=!1;if(!Ft(e)){const c=d=>{const S=WR(d,t,!0);S&&(u=!0,sn(l,S))};!n&&t.mixins.length&&t.mixins.forEach(c),e.extends&&c(e.extends),e.mixins&&e.mixins.forEach(c)}return!o&&!u?(ln(e)&&r.set(e,null),null):(Rt(o)?o.forEach(c=>l[c]=null):sn(l,o),ln(e)&&r.set(e,l),l)}function Af(e,t){return!e||!Co(t)?!1:t.startsWith(Cf)?!0:(t=t.slice(2).replace(/Once$/,""),_n(e,t[0].toLowerCase()+t.slice(1))||_n(e,ei(t))||_n(e,t))}let Yn=null,wl=null;function ec(e){const t=Yn;return Yn=e,wl=e&&e.type.__scopeId||null,wl||(wl=e&&e.type._scopeId||null),t}function h3(e){wl=e}function E3(){wl=null}const S3=e=>sS;function sS(e,t=Yn,n){if(!t||e._n)return e;const r=(...a)=>{r._d&&Vh(-1);const o=ec(t);let l;try{l=e(...a)}finally{ec(o),r._d&&Vh(1)}return l};return r._n=!0,r._c=!0,r._d=!0,n&&(r._ns=!0),r}function pd(e){const{type:t,vnode:n,proxy:r,withProxy:a,props:o,propsOptions:[l],slots:u,attrs:c,emit:d,render:S,renderCache:_,data:E,setupState:T,ctx:y,inheritAttrs:M}=e;let v,A;const O=ec(e);try{if(n.shapeFlag&4){const R=a||r;v=Pi(S.call(R,R,_,o,T,E,y)),A=c}else{const R=t;v=Pi(R.length>1?R(o,{attrs:c,slots:u,emit:d}):R(o,null)),A=t.props?c:v3(c)}}catch(R){Fu.length=0,el(R,e,1),v=En(Dr)}let N=v;if(A&&M!==!1){const R=Object.keys(A),{shapeFlag:L}=N;R.length&&L&7&&(l&&R.some(YE)&&(A=T3(A,l)),N=va(N,A))}if(Sn("INSTANCE_ATTRS_CLASS_STYLE",e)&&n.shapeFlag&4&&N.shapeFlag&7){const{class:R,style:L}=n.props||{};(R||L)&&(N=va(N,{class:R,style:L}))}return n.dirs&&(N=va(N),N.dirs=N.dirs?N.dirs.concat(n.dirs):n.dirs),n.transition&&(N.transition=n.transition),v=N,ec(O),v}function b3(e){let t;for(let n=0;n<e.length;n++){const r=e[n];if(Bi(r)){if(r.type!==Dr||r.children==="v-if"){if(t)return;t=r}}else return}return t}const v3=e=>{let t;for(const n in e)(n==="class"||n==="style"||Co(n))&&((t||(t={}))[n]=e[n]);return t},T3=(e,t)=>{const n={};for(const r in e)(!YE(r)||!(r.slice(9)in t))&&(n[r]=e[r]);return n};function y3(e,t,n){const{props:r,children:a,component:o}=e,{props:l,children:u,patchFlag:c}=t,d=o.emitsOptions;if(t.dirs||t.transition)return!0;if(n&&c>=0){if(c&1024)return!0;if(c&16)return r?vC(r,l,d):!!l;if(c&8){const S=t.dynamicProps;for(let _=0;_<S.length;_++){const E=S[_];if(l[E]!==r[E]&&!Af(d,E))return!0}}}else return(a||u)&&(!u||!u.$stable)?!0:r===l?!1:r?l?vC(r,l,d):!0:!!l;return!1}function vC(e,t,n){const r=Object.keys(t);if(r.length!==Object.keys(e).length)return!0;for(let a=0;a<r.length;a++){const o=r[a];if(t[o]!==e[o]&&!Af(n,o))return!0}return!1}function lS({vnode:e,parent:t},n){for(;t&&t.subTree===e;)(e=t.vnode).el=n,t=t.parent}const uS="components",C3="directives",A3="filters";function O3(e,t){return Of(uS,e,!0,t)||e}const VR=Symbol.for("v-ndc");function zR(e){return xn(e)?Of(uS,e,!1)||e:e||VR}function KR(e){return Of(C3,e)}function $R(e){return Of(A3,e)}function Of(e,t,n=!0,r=!1){const a=Yn||Xn;if(a){const o=a.type;if(e===uS){const u=Qh(o,!1);if(u&&(u===t||u===ni(t)||u===gc(ni(t))))return o}const l=TC(a[e]||o[e],t)||TC(a.appContext[e],t);return!l&&r?o:l}}function TC(e,t){return e&&(e[t]||e[ni(t)]||e[gc(ni(t))])}const QR=e=>e.__isSuspense,R3={name:"Suspense",__isSuspense:!0,process(e,t,n,r,a,o,l,u,c,d){e==null?I3(t,n,r,a,o,l,u,c,d):D3(e,t,n,r,a,l,u,c,d)},hydrate:x3,create:cS,normalize:w3},N3=R3;function tc(e,t){const n=e.props&&e.props[t];Ft(n)&&n()}function I3(e,t,n,r,a,o,l,u,c){const{p:d,o:{createElement:S}}=c,_=S("div"),E=e.suspense=cS(e,a,r,t,_,n,o,l,u,c);d(null,E.pendingBranch=e.ssContent,_,null,r,E,o,l),E.deps>0?(tc(e,"onPending"),tc(e,"onFallback"),d(null,e.ssFallback,t,n,r,null,o,l),Ll(E,e.ssFallback)):E.resolve(!1,!0)}function D3(e,t,n,r,a,o,l,u,{p:c,um:d,o:{createElement:S}}){const _=t.suspense=e.suspense;_.vnode=t,t.el=e.el;const E=t.ssContent,T=t.ssFallback,{activeBranch:y,pendingBranch:M,isInFallback:v,isHydrating:A}=_;if(M)_.pendingBranch=E,ba(E,M)?(c(M,E,_.hiddenContainer,null,a,_,o,l,u),_.deps<=0?_.resolve():v&&(c(y,T,n,r,a,null,o,l,u),Ll(_,T))):(_.pendingId++,A?(_.isHydrating=!1,_.activeBranch=M):d(M,a,_),_.deps=0,_.effects.length=0,_.hiddenContainer=S("div"),v?(c(null,E,_.hiddenContainer,null,a,_,o,l,u),_.deps<=0?_.resolve():(c(y,T,n,r,a,null,o,l,u),Ll(_,T))):y&&ba(E,y)?(c(y,E,n,r,a,_,o,l,u),_.resolve(!0)):(c(null,E,_.hiddenContainer,null,a,_,o,l,u),_.deps<=0&&_.resolve()));else if(y&&ba(E,y))c(y,E,n,r,a,_,o,l,u),Ll(_,E);else if(tc(t,"onPending"),_.pendingBranch=E,_.pendingId++,c(null,E,_.hiddenContainer,null,a,_,o,l,u),_.deps<=0)_.resolve();else{const{timeout:O,pendingId:N}=_;O>0?setTimeout(()=>{_.pendingId===N&&_.fallback(T)},O):O===0&&_.fallback(T)}}function cS(e,t,n,r,a,o,l,u,c,d,S=!1){const{p:_,m:E,um:T,n:y,o:{parentNode:M,remove:v}}=d;let A;const O=L3(e);O&&t!=null&&t.pendingBranch&&(A=t.pendingId,t.deps++);const N=e.props?Od(e.props.timeout):void 0,R={vnode:e,parent:t,parentComponent:n,isSVG:l,container:r,hiddenContainer:a,anchor:o,deps:0,pendingId:0,timeout:typeof N=="number"?N:-1,activeBranch:null,pendingBranch:null,isInFallback:!0,isHydrating:S,isUnmounted:!1,effects:[],resolve(L=!1,I=!1){const{vnode:h,activeBranch:k,pendingBranch:F,pendingId:z,effects:K,parentComponent:ue,container:Z}=R;let fe=!1;if(R.isHydrating)R.isHydrating=!1;else if(!L){fe=k&&F.transition&&F.transition.mode==="out-in",fe&&(k.transition.afterLeave=()=>{z===R.pendingId&&(E(F,Z,te,0),Id(K))});let{anchor:te}=R;k&&(te=y(k),T(k,ue,R,!0)),fe||E(F,Z,te,0)}Ll(R,F),R.pendingBranch=null,R.isInFallback=!1;let V=R.parent,ne=!1;for(;V;){if(V.pendingBranch){V.effects.push(...K),ne=!0;break}V=V.parent}!ne&&!fe&&Id(K),R.effects=[],O&&t&&t.pendingBranch&&A===t.pendingId&&(t.deps--,t.deps===0&&!I&&t.resolve()),tc(h,"onResolve")},fallback(L){if(!R.pendingBranch)return;const{vnode:I,activeBranch:h,parentComponent:k,container:F,isSVG:z}=R;tc(I,"onFallback");const K=y(h),ue=()=>{!R.isInFallback||(_(null,L,F,K,k,null,z,u,c),Ll(R,L))},Z=L.transition&&L.transition.mode==="out-in";Z&&(h.transition.afterLeave=ue),R.isInFallback=!0,T(h,k,null,!0),Z||ue()},move(L,I,h){R.activeBranch&&E(R.activeBranch,L,I,h),R.container=L},next(){return R.activeBranch&&y(R.activeBranch)},registerDep(L,I){const h=!!R.pendingBranch;h&&R.deps++;const k=L.vnode.el;L.asyncDep.catch(F=>{el(F,L,0)}).then(F=>{if(L.isUnmounted||R.isUnmounted||R.pendingId!==L.suspenseId)return;L.asyncResolved=!0;const{vnode:z}=L;zh(L,F,!1),k&&(z.el=k);const K=!k&&L.subTree.el;I(L,z,M(k||L.subTree.el),k?null:y(L.subTree),R,l,c),K&&v(K),lS(L,z.el),h&&--R.deps===0&&R.resolve()})},unmount(L,I){R.isUnmounted=!0,R.activeBranch&&T(R.activeBranch,n,L,I),R.pendingBranch&&T(R.pendingBranch,n,L,I)}};return R}function x3(e,t,n,r,a,o,l,u,c){const d=t.suspense=cS(t,r,n,e.parentNode,document.createElement("div"),null,a,o,l,u,!0),S=c(e,d.pendingBranch=t.ssContent,n,d,o,l);return d.deps===0&&d.resolve(!1,!0),S}function w3(e){const{shapeFlag:t,children:n}=e,r=t&32;e.ssContent=yC(r?n.default:n),e.ssFallback=r?yC(n.fallback):En(Dr)}function yC(e){let t;if(Ft(e)){const n=Xs&&e._c;n&&(e._d=!1,ki()),e=e(),n&&(e._d=!0,t=bi,HN())}return Rt(e)&&(e=b3(e)),e=Pi(e),t&&!e.dynamicChildren&&(e.dynamicChildren=t.filter(n=>n!==e)),e}function jR(e,t){t&&t.pendingBranch?Rt(e)?t.effects.push(...e):t.effects.push(e):Id(e)}function Ll(e,t){e.activeBranch=t;const{vnode:n,parentComponent:r}=e,a=n.el=t.el;r&&r.subTree===n&&(r.vnode.el=a,lS(r,a))}function L3(e){var t;return((t=e.props)==null?void 0:t.suspensible)!=null&&e.props.suspensible!==!1}const M3={beforeMount:"bind",mounted:"inserted",updated:["update","componentUpdated"],unmounted:"unbind"};function k3(e,t,n){const r=M3[e];if(r)if(Rt(r)){const a=[];return r.forEach(o=>{const l=t[o];l&&(yo("CUSTOM_DIR",n,o,e),a.push(l))}),a.length?a:void 0}else return t[r]&&yo("CUSTOM_DIR",n,r,e),t[r]}function P3(e,t){return Sc(e,null,t)}function XR(e,t){return Sc(e,null,{flush:"post"})}function F3(e,t){return Sc(e,null,{flush:"sync"})}const rd={};function Ps(e,t,n){return Sc(e,t,n)}function Sc(e,t,{immediate:n,deep:r,flush:a,onTrack:o,onTrigger:l}=yn){var u;const c=yR()===((u=Xn)==null?void 0:u.scope)?Xn:null;let d,S=!1,_=!1;if(sr(e)?(d=()=>e.value,S=ju(e)):So(e)?(d=()=>e,r=!0):Rt(e)?(_=!0,S=e.some(R=>So(R)||ju(R)),d=()=>e.map(R=>{if(sr(R))return R.value;if(So(R))return Zo(R);if(Ft(R))return Ya(R,c,2)})):Ft(e)?t?d=()=>Ya(e,c,2):d=()=>{if(!(c&&c.isUnmounted))return E&&E(),Ti(e,c,3,[T])}:d=vi,t&&!r){const R=d;d=()=>{const L=R();return Rt(L)&&yf("WATCH_ARRAY",c)&&Zo(L),L}}if(t&&r){const R=d;d=()=>Zo(R())}let E,T=R=>{E=O.onStop=()=>{Ya(R,c,4)}},y;if(Yl)if(T=vi,t?n&&Ti(t,c,3,[d(),_?[]:void 0,T]):d(),a==="sync"){const R=jN();y=R.__watcherHandles||(R.__watcherHandles=[])}else return vi;let M=_?new Array(e.length).fill(rd):rd;const v=()=>{if(!!O.active)if(t){const R=O.run();(r||S||(_?R.some((L,I)=>os(L,M[I])):os(R,M))||Rt(R)&&Sn("WATCH_ARRAY",c))&&(E&&E(),Ti(t,c,3,[R,M===rd?void 0:_&&M[0]===rd?[]:M,T]),M=R)}else O.run()};v.allowRecurse=!!t;let A;a==="sync"?A=v:a==="post"?A=()=>$n(v,c&&c.suspense):(v.pre=!0,c&&(v.id=c.uid),A=()=>Tf(v));const O=new Gl(d,A);t?n?v():M=O.run():a==="post"?$n(O.run.bind(O),c&&c.suspense):O.run();const N=()=>{O.stop(),c&&c.scope&&WE(c.scope.effects,O)};return y&&y.push(N),N}function B3(e,t,n){const r=this.proxy,a=xn(e)?e.includes(".")?ZR(r,e):()=>r[e]:e.bind(r,r);let o;Ft(t)?o=t:(o=t.handler,n=t);const l=Xn;us(this);const u=Sc(a,o.bind(r),n);return l?us(l):ts(),u}function ZR(e,t){const n=t.split(".");return()=>{let r=e;for(let a=0;a<n.length&&r;a++)r=r[n[a]];return r}}function Zo(e,t){if(!ln(e)||e.__v_skip||(t=t||new Set,t.has(e)))return e;if(t.add(e),sr(e))Zo(e.value,t);else if(Rt(e))for(let n=0;n<e.length;n++)Zo(e[n],t);else if(Js(e)||Rl(e))e.forEach(n=>{Zo(n,t)});else if(Cd(e))for(const n in e)Zo(e[n],t);return e}function JR(e,t){const n=Yn;if(n===null)return e;const r=Lf(n)||n.proxy,a=e.dirs||(e.dirs=[]);for(let o=0;o<t.length;o++){let[l,u,c,d=yn]=t[o];l&&(Ft(l)&&(l={mounted:l,updated:l}),l.deep&&Zo(u),a.push({dir:l,instance:r,value:u,oldValue:void 0,arg:c,modifiers:d}))}return e}function Ba(e,t,n,r){const a=e.dirs,o=t&&t.dirs;for(let l=0;l<a.length;l++){const u=a[l];o&&(u.oldValue=o[l].value);let c=u.dir[r];c||(c=k3(r,u.dir,n)),c&&(nu(),Ti(c,n,8,[e.el,u,e,t]),ru())}}const Ko=Symbol("_leaveCb"),id=Symbol("_enterCb");function dS(){const e={isMounted:!1,isLeaving:!1,isUnmounting:!1,leavingVNodes:new Map};return vc(()=>{e.isMounted=!0}),nc(()=>{e.isUnmounting=!0}),e}const ta=[Function,Array],fS={mode:String,appear:Boolean,persisted:Boolean,onBeforeEnter:ta,onEnter:ta,onAfterEnter:ta,onEnterCancelled:ta,onBeforeLeave:ta,onLeave:ta,onAfterLeave:ta,onLeaveCancelled:ta,onBeforeAppear:ta,onAppear:ta,onAfterAppear:ta,onAppearCancelled:ta},eN={name:"BaseTransition",props:fS,setup(e,{slots:t}){const n=Aa(),r=dS();let a;return()=>{const o=t.default&&Rf(t.default(),!0);if(!o||!o.length)return;let l=o[0];if(o.length>1){for(const M of o)if(M.type!==Dr){l=M;break}}const u=pn(e),{mode:c}=u;if(r.isLeaving)return Jg(l);const d=CC(l);if(!d)return Jg(l);const S=Hl(d,u,r,n);Qs(d,S);const _=n.subTree,E=_&&CC(_);let T=!1;const{getTransitionKey:y}=d.type;if(y){const M=y();a===void 0?a=M:M!==a&&(a=M,T=!0)}if(E&&E.type!==Dr&&(!ba(d,E)||T)){const M=Hl(E,u,r,n);if(Qs(E,M),c==="out-in")return r.isLeaving=!0,M.afterLeave=()=>{r.isLeaving=!1,n.update.active!==!1&&n.update()},Jg(l);c==="in-out"&&d.type!==Dr&&(M.delayLeave=(v,A,O)=>{const N=nN(r,E);N[String(E.key)]=E,v[Ko]=()=>{A(),v[Ko]=void 0,delete S.delayedLeave},S.delayedLeave=O})}return l}}};eN.__isBuiltIn=!0;const tN=eN;function nN(e,t){const{leavingVNodes:n}=e;let r=n.get(t.type);return r||(r=Object.create(null),n.set(t.type,r)),r}function Hl(e,t,n,r){const{appear:a,mode:o,persisted:l=!1,onBeforeEnter:u,onEnter:c,onAfterEnter:d,onEnterCancelled:S,onBeforeLeave:_,onLeave:E,onAfterLeave:T,onLeaveCancelled:y,onBeforeAppear:M,onAppear:v,onAfterAppear:A,onAppearCancelled:O}=t,N=String(e.key),R=nN(n,e),L=(k,F)=>{k&&Ti(k,r,9,F)},I=(k,F)=>{const z=F[1];L(k,F),Rt(k)?k.every(K=>K.length<=1)&&z():k.length<=1&&z()},h={mode:o,persisted:l,beforeEnter(k){let F=u;if(!n.isMounted)if(a)F=M||u;else return;k[Ko]&&k[Ko](!0);const z=R[N];z&&ba(e,z)&&z.el[Ko]&&z.el[Ko](),L(F,[k])},enter(k){let F=c,z=d,K=S;if(!n.isMounted)if(a)F=v||c,z=A||d,K=O||S;else return;let ue=!1;const Z=k[id]=fe=>{ue||(ue=!0,fe?L(K,[k]):L(z,[k]),h.delayedLeave&&h.delayedLeave(),k[id]=void 0)};F?I(F,[k,Z]):Z()},leave(k,F){const z=String(e.key);if(k[id]&&k[id](!0),n.isUnmounting)return F();L(_,[k]);let K=!1;const ue=k[Ko]=Z=>{K||(K=!0,F(),Z?L(y,[k]):L(T,[k]),k[Ko]=void 0,R[z]===e&&delete R[z])};R[z]=e,E?I(E,[k,ue]):ue()},clone(k){return Hl(k,t,n,r)}};return h}function Jg(e){if(bc(e))return e=va(e),e.children=null,e}function CC(e){return bc(e)?e.children?e.children[0]:void 0:e}function Qs(e,t){e.shapeFlag&6&&e.component?Qs(e.component.subTree,t):e.shapeFlag&128?(e.ssContent.transition=t.clone(e.ssContent),e.ssFallback.transition=t.clone(e.ssFallback)):e.transition=t}function Rf(e,t=!1,n){let r=[],a=0;for(let o=0;o<e.length;o++){let l=e[o];const u=n==null?l.key:String(n)+String(l.key!=null?l.key:o);l.type===hr?(l.patchFlag&128&&a++,r=r.concat(Rf(l.children,t,u))):(t||l.type!==Dr)&&r.push(u!=null?va(l,{key:u}):l)}if(a>1)for(let o=0;o<r.length;o++)r[o].patchFlag=-2;return r}/*! #__NO_SIDE_EFFECTS__ */function pS(e,t){return Ft(e)?(()=>sn({name:e.name},t,{setup:e}))():e}const Fs=e=>!!e.type.__asyncLoader;/*! #__NO_SIDE_EFFECTS__ */function _d(e){Ft(e)&&(e={loader:e});const{loader:t,loadingComponent:n,errorComponent:r,delay:a=200,timeout:o,suspensible:l=!0,onError:u}=e;let c=null,d,S=0;const _=()=>(S++,c=null,E()),E=()=>{let T;return c||(T=c=t().catch(y=>{if(y=y instanceof Error?y:new Error(String(y)),u)return new Promise((M,v)=>{u(y,()=>M(_()),()=>v(y),S+1)});throw y}).then(y=>T!==c&&c?c:(y&&(y.__esModule||y[Symbol.toStringTag]==="Module")&&(y=y.default),d=y,y)))};return pS({name:"AsyncComponentWrapper",__asyncLoader:E,get __asyncResolved(){return d},setup(){const T=Xn;if(d)return()=>eh(d,T);const y=O=>{c=null,el(O,T,13,!r)};if(l&&T.suspense||Yl)return E().then(O=>()=>eh(O,T)).catch(O=>(y(O),()=>r?En(r,{error:O}):null));const M=Dl(!1),v=Dl(),A=Dl(!!a);return a&&setTimeout(()=>{A.value=!1},a),o!=null&&setTimeout(()=>{if(!M.value&&!v.value){const O=new Error(`Async component timed out after ${o}ms.`);y(O),v.value=O}},o),E().then(()=>{M.value=!0,T.parent&&bc(T.parent.vnode)&&Tf(T.parent.update)}).catch(O=>{y(O),v.value=O}),()=>{if(M.value&&d)return eh(d,T);if(v.value&&r)return En(r,{error:v.value});if(n&&!A.value)return En(n)}}})}function eh(e,t){const{ref:n,props:r,children:a,ce:o}=t.vnode,l=En(e,r,a);return l.ref=n,l.ce=o,delete t.vnode.ce,l}const bc=e=>e.type.__isKeepAlive,rN={name:"KeepAlive",__isKeepAlive:!0,props:{include:[String,RegExp,Array],exclude:[String,RegExp,Array],max:[String,Number]},setup(e,{slots:t}){const n=Aa(),r=n.ctx;if(!r.renderer)return()=>{const O=t.default&&t.default();return O&&O.length===1?O[0]:O};const a=new Map,o=new Set;let l=null;const u=n.suspense,{renderer:{p:c,m:d,um:S,o:{createElement:_}}}=r,E=_("div");r.activate=(O,N,R,L,I)=>{const h=O.component;d(O,N,R,0,u),c(h.vnode,O,N,R,h,u,L,O.slotScopeIds,I),$n(()=>{h.isDeactivated=!1,h.a&&Jo(h.a);const k=O.props&&O.props.onVnodeMounted;k&&Ei(k,h.parent,O)},u)},r.deactivate=O=>{const N=O.component;d(O,E,null,1,u),$n(()=>{N.da&&Jo(N.da);const R=O.props&&O.props.onVnodeUnmounted;R&&Ei(R,N.parent,O),N.isDeactivated=!0},u)};function T(O){th(O),S(O,n,u,!0)}function y(O){a.forEach((N,R)=>{const L=Qh(N.type);L&&(!O||!O(L))&&M(R)})}function M(O){const N=a.get(O);!l||!ba(N,l)?T(N):l&&th(l),a.delete(O),o.delete(O)}Ps(()=>[e.include,e.exclude],([O,N])=>{O&&y(R=>xu(O,R)),N&&y(R=>!xu(N,R))},{flush:"post",deep:!0});let v=null;const A=()=>{v!=null&&a.set(v,nh(n.subTree))};return vc(A),If(A),nc(()=>{a.forEach(O=>{const{subTree:N,suspense:R}=n,L=nh(N);if(O.type===L.type&&O.key===L.key){th(L);const I=L.component.da;I&&$n(I,R);return}T(O)})}),()=>{if(v=null,!t.default)return null;const O=t.default(),N=O[0];if(O.length>1)return l=null,O;if(!Bi(N)||!(N.shapeFlag&4)&&!(N.shapeFlag&128))return l=null,N;let R=nh(N);const L=R.type,I=Qh(Fs(R)?R.type.__asyncResolved||{}:L),{include:h,exclude:k,max:F}=e;if(h&&(!I||!xu(h,I))||k&&I&&xu(k,I))return l=R,N;const z=R.key==null?L:R.key,K=a.get(z);return R.el&&(R=va(R),N.shapeFlag&128&&(N.ssContent=R)),v=z,K?(R.el=K.el,R.component=K.component,R.transition&&Qs(R,R.transition),R.shapeFlag|=512,o.delete(z),o.add(z)):(o.add(z),F&&o.size>parseInt(F,10)&&M(o.values().next().value)),R.shapeFlag|=256,l=R,QR(N.type)?N:R}}};rN.__isBuildIn=!0;const iN=rN;function xu(e,t){return Rt(e)?e.some(n=>xu(n,t)):xn(e)?e.split(",").includes(t):oU(e)?e.test(t):!1}function aN(e,t){sN(e,"a",t)}function oN(e,t){sN(e,"da",t)}function sN(e,t,n=Xn){const r=e.__wdc||(e.__wdc=()=>{let a=n;for(;a;){if(a.isDeactivated)return;a=a.parent}return e()});if(Nf(t,r,n),n){let a=n.parent;for(;a&&a.parent;)bc(a.parent.vnode)&&U3(r,t,n,a),a=a.parent}}function U3(e,t,n,r){const a=Nf(t,e,r,!0);rc(()=>{WE(r[t],a)},n)}function th(e){e.shapeFlag&=-257,e.shapeFlag&=-513}function nh(e){return e.shapeFlag&128?e.ssContent:e}function Nf(e,t,n=Xn,r=!1){if(n){const a=n[e]||(n[e]=[]),o=t.__weh||(t.__weh=(...l)=>{if(n.isUnmounted)return;nu(),us(n);const u=Ti(t,n,e,l);return ts(),ru(),u});return r?a.unshift(o):a.push(o),o}}const Ao=e=>(t,n=Xn)=>(!Yl||e==="sp")&&Nf(e,(...r)=>t(...r),n),lN=Ao("bm"),vc=Ao("m"),uN=Ao("bu"),If=Ao("u"),nc=Ao("bum"),rc=Ao("um"),cN=Ao("sp"),dN=Ao("rtg"),fN=Ao("rtc");function pN(e,t=Xn){Nf("ec",e,t)}function G3(e){Ir("INSTANCE_CHILDREN",e);const t=e.subTree,n=[];return t&&_N(t,n),n}function _N(e,t){if(e.component)t.push(e.component.proxy);else if(e.shapeFlag&16){const n=e.children;for(let r=0;r<n.length;r++)_N(n[r],t)}}function mN(e){Ir("INSTANCE_LISTENERS",e);const t={},n=e.vnode.props;if(!n)return t;for(const r in n)Co(r)&&(t[r[2].toLowerCase()+r.slice(3)]=n[r]);return t}function H3(e){const t=e.type,n=t.render;if(!(!n||n._rc||n._compatChecked||n._compatWrapped)){if(n.length>=2){n._compatChecked=!0;return}if(yf("RENDER_FUNCTION",e)){const r=t.render=function(){return n.call(this,xd)};r._compatWrapped=!0}}}function xd(e,t,n){if(e||(e=Dr),typeof e=="string"){const o=ei(e);(o==="transition"||o==="transition-group"||o==="keep-alive")&&(e=`__compat__${o}`),e=zR(e)}const r=arguments.length,a=Rt(t);return r===2||a?ln(t)&&!a?Bi(t)?ad(En(e,null,[t])):ad(OC(En(e,AC(t,e)),t)):ad(En(e,null,t)):(Bi(n)&&(n=[n]),ad(OC(En(e,AC(t,e),n),t)))}const q3=Jl("staticStyle,staticClass,directives,model,hook");function AC(e,t){if(!e)return null;const n={};for(const r in e)if(r==="attrs"||r==="domProps"||r==="props")sn(n,e[r]);else if(r==="on"||r==="nativeOn"){const a=e[r];for(const o in a){let l=Y3(o);r==="nativeOn"&&(l+="Native");const u=n[l],c=a[o];u!==c&&(u?n[l]=[].concat(u,c):n[l]=c)}}else q3(r)||(n[r]=e[r]);if(e.staticClass&&(n.class=Va([e.staticClass,n.class])),e.staticStyle&&(n.style=tu([e.staticStyle,n.style])),e.model&&ln(t)){const{prop:r="value",event:a="input"}=t.model||{};n[r]=e.model.value,n[Cf+a]=e.model.callback}return n}function Y3(e){return e[0]==="&"&&(e=e.slice(1)+"Passive"),e[0]==="~"&&(e=e.slice(1)+"Once"),e[0]==="!"&&(e=e.slice(1)+"Capture"),Il(e)}function OC(e,t){return t&&t.directives?JR(e,t.directives.map(({name:n,value:r,arg:a,modifiers:o})=>[KR(n),r,a,o])):e}function ad(e){const{props:t,children:n}=e;let r;if(e.shapeFlag&6&&Rt(n)){r={};for(let o=0;o<n.length;o++){const l=n[o],u=Bi(l)&&l.props&&l.props.slot||"default",c=r[u]||(r[u]=[]);Bi(l)&&l.type==="template"?c.push(l.children):c.push(l)}if(r)for(const o in r){const l=r[o];r[o]=()=>l,r[o]._ns=!0}}const a=t&&t.scopedSlots;return a&&(delete t.scopedSlots,r?sn(r,a):r=a),r&&xf(e,r),e}function gN(e){if(Sn("RENDER_FUNCTION",Yn,!0)&&Sn("PRIVATE_APIS",Yn,!0)){const t=Yn,n=()=>e.component&&e.component.proxy;let r;Object.defineProperties(e,{tag:{get:()=>e.type},data:{get:()=>e.props||{},set:a=>e.props=a},elm:{get:()=>e.el},componentInstance:{get:n},child:{get:n},text:{get:()=>xn(e.children)?e.children:null},context:{get:()=>t&&t.proxy},componentOptions:{get:()=>{if(e.shapeFlag&4)return r||(r={Ctor:e.type,propsData:e.props,children:e.children})}}})}}const rh=new WeakMap,hN={get(e,t){const n=e[t];return n&&n()}};function W3(e){if(rh.has(e))return rh.get(e);const t=e.render,n=(r,a)=>{const o=Aa(),l={props:r,children:o.vnode.children||[],data:o.vnode.props||{},scopedSlots:a.slots,parent:o.parent&&o.parent.proxy,slots(){return new Proxy(a.slots,hN)},get listeners(){return mN(o)},get injections(){if(e.inject){const u={};return AN(e.inject,u),u}return{}}};return t(xd,l)};return n.props=e.props,n.displayName=e.name,n.compatConfig=e.compatConfig,n.inheritAttrs=!1,rh.set(e,n),n}function _S(e,t,n,r){let a;const o=n&&n[r];if(Rt(e)||xn(e)){a=new Array(e.length);for(let l=0,u=e.length;l<u;l++)a[l]=t(e[l],l,void 0,o&&o[l])}else if(typeof e=="number"){a=new Array(e);for(let l=0;l<e;l++)a[l]=t(l+1,l,void 0,o&&o[l])}else if(ln(e))if(e[Symbol.iterator])a=Array.from(e,(l,u)=>t(l,u,void 0,o&&o[u]));else{const l=Object.keys(e);a=new Array(l.length);for(let u=0,c=l.length;u<c;u++){const d=l[u];a[u]=t(e[d],d,u,o&&o[u])}}else a=[];return n&&(n[r]=a),a}function EN(e,t){for(let n=0;n<t.length;n++){const r=t[n];if(Rt(r))for(let a=0;a<r.length;a++)e[r[a].name]=r[a].fn;else r&&(e[r.name]=r.key?(...a)=>{const o=r.fn(...a);return o&&(o.key=r.key),o}:r.fn)}return e}function SN(e,t,n={},r,a){if(Yn.isCE||Yn.parent&&Fs(Yn.parent)&&Yn.parent.isCE)return t!=="default"&&(n.name=t),En("slot",n,r&&r());let o=e[t];o&&o._c&&(o._d=!1),ki();const l=o&&bN(o(n)),u=hS(hr,{key:n.key||l&&l.key||`_${t}`},l||(r?r():[]),l&&e._===1?64:-2);return!a&&u.scopeId&&(u.slotScopeIds=[u.scopeId+"-s"]),o&&o._c&&(o._d=!0),u}function bN(e){return e.some(t=>Bi(t)?!(t.type===Dr||t.type===hr&&!bN(t.children)):!0)?e:null}function vN(e,t){const n={};for(const r in e)n[t&&/[A-Z]/.test(r)?`on:${r}`:Il(r)]=e[r];return n}function V3(e){const t={};for(let n=0;n<e.length;n++)e[n]&&sn(t,e[n]);return t}function z3(e,t,n,r,a){if(n&&ln(n)){Rt(n)&&(n=V3(n));for(const o in n)if(Nl(o))e[o]=n[o];else if(o==="class")e.class=Va([e.class,n.class]);else if(o==="style")e.style=Va([e.style,n.style]);else{const l=e.attrs||(e.attrs={}),u=ni(o),c=ei(o);if(!(u in l)&&!(c in l)&&(l[o]=n[o],a)){const d=e.on||(e.on={});d[`update:${o}`]=function(S){n[o]=S}}}}return e}function K3(e,t){return wf(e,vN(t))}function $3(e,t,n,r,a){return a&&(r=wf(r,a)),SN(e.slots,t,r,n&&(()=>n))}function Q3(e,t,n){return EN(t||{$stable:!n},TN(e))}function TN(e){for(let t=0;t<e.length;t++){const n=e[t];n&&(Rt(n)?TN(n):n.name=n.key||"default")}return e}const RC=new WeakMap;function j3(e,t){let n=RC.get(e);if(n||RC.set(e,n=[]),n[t])return n[t];const r=e.type.staticRenderFns[t],a=e.proxy;return n[t]=r.call(a,null,a)}function X3(e,t,n,r,a,o){const u=e.appContext.config.keyCodes||{},c=u[n]||r;if(o&&a&&!u[n])return NC(o,a);if(c)return NC(c,t);if(a)return ei(a)!==n}function NC(e,t){return Rt(e)?!e.includes(t):e!==t}function Z3(e){return e}function J3(e,t){for(let n=0;n<t.length;n+=2){const r=t[n];typeof r=="string"&&r&&(e[t[n]]=t[n+1])}return e}function eG(e,t){return typeof e=="string"?t+e:e}function tG(e){const t=(r,a,o)=>(r[a]=o,r[a]),n=(r,a)=>{delete r[a]};sn(e,{$set:r=>(Ir("INSTANCE_SET",r),t),$delete:r=>(Ir("INSTANCE_DELETE",r),n),$mount:r=>(Ir("GLOBAL_MOUNT",null),r.ctx._compat_mount||vi),$destroy:r=>(Ir("INSTANCE_DESTROY",r),r.ctx._compat_destroy||vi),$slots:r=>Sn("RENDER_FUNCTION",r)&&r.render&&r.render._compatWrapped?new Proxy(r.slots,hN):r.slots,$scopedSlots:r=>{Ir("INSTANCE_SCOPED_SLOTS",r);const a={};for(const o in r.slots){const l=r.slots[o];l._ns||(a[o]=l)}return a},$on:r=>aS.bind(null,r),$once:r=>f3.bind(null,r),$off:r=>oS.bind(null,r),$children:G3,$listeners:mN}),Sn("PRIVATE_APIS",null)&&sn(e,{$vnode:r=>r.vnode,$options:r=>{const a=sn({},Tc(r));return a.parent=r.proxy.$parent,a.propsData=r.vnode.props,a},_self:r=>r.proxy,_uid:r=>r.uid,_data:r=>r.data,_isMounted:r=>r.isMounted,_isDestroyed:r=>r.isUnmounted,$createElement:()=>xd,_c:()=>xd,_o:()=>Z3,_n:()=>Qu,_s:()=>Rd,_l:()=>_S,_t:r=>$3.bind(null,r),_q:()=>To,_i:()=>hc,_m:r=>j3.bind(null,r),_f:()=>$R,_k:r=>X3.bind(null,r),_b:()=>z3,_v:()=>ql,_e:()=>Ld,_u:()=>Q3,_g:()=>K3,_d:()=>J3,_p:()=>eG})}const Uh=e=>e?VN(e)?Lf(e)||e.proxy:Uh(e.parent):null,Ml=sn(Object.create(null),{$:e=>e,$el:e=>e.vnode.el,$data:e=>e.data,$props:e=>e.props,$attrs:e=>e.attrs,$slots:e=>e.slots,$refs:e=>e.refs,$parent:e=>Uh(e.parent),$root:e=>Uh(e.root),$emit:e=>e.emit,$options:e=>Tc(e),$forceUpdate:e=>e.f||(e.f=()=>Tf(e.update)),$nextTick:e=>e.n||(e.n=Ec.bind(e.proxy)),$watch:e=>B3.bind(e)});tG(Ml);const ih=(e,t)=>e!==yn&&!e.__isScriptSetup&&_n(e,t),Gh={get({_:e},t){const{ctx:n,setupState:r,data:a,props:o,accessCache:l,type:u,appContext:c}=e;let d;if(t[0]!=="$"){const T=l[t];if(T!==void 0)switch(T){case 1:return r[t];case 2:return a[t];case 4:return n[t];case 3:return o[t]}else{if(ih(r,t))return l[t]=1,r[t];if(a!==yn&&_n(a,t))return l[t]=2,a[t];if((d=e.propsOptions[0])&&_n(d,t))return l[t]=3,o[t];if(n!==yn&&_n(n,t))return l[t]=4,n[t];Hh&&(l[t]=0)}}const S=Ml[t];let _,E;if(S)return t==="$attrs"&&ri(e,"get",t),S(e);if((_=u.__cssModules)&&(_=_[t]))return _;if(n!==yn&&_n(n,t))return l[t]=4,n[t];if(E=c.config.globalProperties,_n(E,t)){const T=Object.getOwnPropertyDescriptor(E,t);if(T.get)return T.get.call(e.proxy);{const y=E[t];return Ft(y)?Object.assign(y.bind(e.proxy),y):y}}},set({_:e},t,n){const{data:r,setupState:a,ctx:o}=e;return ih(a,t)?(a[t]=n,!0):r!==yn&&_n(r,t)?(r[t]=n,!0):_n(e.props,t)||t[0]==="$"&&t.slice(1)in e?!1:(o[t]=n,!0)},has({_:{data:e,setupState:t,accessCache:n,ctx:r,appContext:a,propsOptions:o}},l){let u;return!!n[l]||e!==yn&&_n(e,l)||ih(t,l)||(u=o[0])&&_n(u,l)||_n(r,l)||_n(Ml,l)||_n(a.config.globalProperties,l)},defineProperty(e,t,n){return n.get!=null?e._.accessCache[t]=0:_n(n,"value")&&this.set(e,t,n.value,null),Reflect.defineProperty(e,t,n)}},nG=sn({},Gh,{get(e,t){if(t!==Symbol.unscopables)return Gh.get(e,t,e)},has(e,t){return t[0]!=="_"&&!dU(t)}});function yN(e,t){for(const n in t){const r=e[n],a=t[n];n in e&&Cd(r)&&Cd(a)?yN(r,a):e[n]=a}return e}function rG(){return null}function iG(){return null}function aG(e){}function oG(e){}function sG(){return null}function lG(){}function uG(e,t){return null}function cG(){return CN().slots}function dG(){return CN().attrs}function fG(e,t,n){const r=Aa();if(n&&n.local){const a=Dl(e[t]);return Ps(()=>e[t],o=>a.value=o),Ps(a,o=>{o!==e[t]&&r.emit(`update:${t}`,o)}),a}else return{__v_isRef:!0,get value(){return e[t]},set value(a){r.emit(`update:${t}`,a)}}}function CN(){const e=Aa();return e.setupContext||(e.setupContext=zN(e))}function ic(e){return Rt(e)?e.reduce((t,n)=>(t[n]=null,t),{}):e}function pG(e,t){const n=ic(e);for(const r in t){if(r.startsWith("__skip"))continue;let a=n[r];a?Rt(a)||Ft(a)?a=n[r]={type:a,default:t[r]}:a.default=t[r]:a===null&&(a=n[r]={default:t[r]}),a&&t[`__skip_${r}`]&&(a.skipFactory=!0)}return n}function _G(e,t){return!e||!t?e||t:Rt(e)&&Rt(t)?e.concat(t):sn({},ic(e),ic(t))}function mG(e,t){const n={};for(const r in e)t.includes(r)||Object.defineProperty(n,r,{enumerable:!0,get:()=>e[r]});return n}function gG(e){const t=Aa();let n=e();return ts(),gf(n)&&(n=n.catch(r=>{throw us(t),r})),[n,()=>us(t)]}let Hh=!0;function hG(e){const t=Tc(e),n=e.proxy,r=e.ctx;Hh=!1,t.beforeCreate&&IC(t.beforeCreate,e,"bc");const{data:a,computed:o,methods:l,watch:u,provide:c,inject:d,created:S,beforeMount:_,mounted:E,beforeUpdate:T,updated:y,activated:M,deactivated:v,beforeDestroy:A,beforeUnmount:O,destroyed:N,unmounted:R,render:L,renderTracked:I,renderTriggered:h,errorCaptured:k,serverPrefetch:F,expose:z,inheritAttrs:K,components:ue,directives:Z,filters:fe}=t;if(d&&AN(d,r,null),l)for(const te in l){const G=l[te];Ft(G)&&(r[te]=G.bind(n))}if(a){const te=a.call(n,n);ln(te)&&(e.data=ls(te))}if(Hh=!0,o)for(const te in o){const G=o[te],se=Ft(G)?G.bind(n,n):Ft(G.get)?G.get.bind(n,n):vi,ve=!Ft(G)&&Ft(G.set)?G.set.bind(n):vi,Ge=KN({get:se,set:ve});Object.defineProperty(r,te,{enumerable:!0,configurable:!0,get:()=>Ge.value,set:oe=>Ge.value=oe})}if(u)for(const te in u)ON(u[te],r,n,te);if(c){const te=Ft(c)?c.call(n):c;Reflect.ownKeys(te).forEach(G=>{IN(G,te[G])})}S&&IC(S,e,"c");function ne(te,G){Rt(G)?G.forEach(se=>te(se.bind(n))):G&&te(G.bind(n))}if(ne(lN,_),ne(vc,E),ne(uN,T),ne(If,y),ne(aN,M),ne(oN,v),ne(pN,k),ne(fN,I),ne(dN,h),ne(nc,O),ne(rc,R),ne(cN,F),A&&yo("OPTIONS_BEFORE_DESTROY",e)&&ne(nc,A),N&&yo("OPTIONS_DESTROYED",e)&&ne(rc,N),Rt(z))if(z.length){const te=e.exposed||(e.exposed={});z.forEach(G=>{Object.defineProperty(te,G,{get:()=>n[G],set:se=>n[G]=se})})}else e.exposed||(e.exposed={});L&&e.render===vi&&(e.render=L),K!=null&&(e.inheritAttrs=K),ue&&(e.components=ue),Z&&(e.directives=Z),fe&&Sn("FILTERS",e)&&(e.filters=fe)}function AN(e,t,n=vi){Rt(e)&&(e=qh(e));for(const r in e){const a=e[r];let o;ln(a)?"default"in a?o=Gs(a.from||r,a.default,!0):o=Gs(a.from||r):o=Gs(a),sr(o)?Object.defineProperty(t,r,{enumerable:!0,configurable:!0,get:()=>o.value,set:l=>o.value=l}):t[r]=o}}function IC(e,t,n){Ti(Rt(e)?e.map(r=>r.bind(t.proxy)):e.bind(t.proxy),t,n)}function ON(e,t,n,r){const a=r.includes(".")?ZR(n,r):()=>n[r];if(xn(e)){const o=t[e];Ft(o)&&Ps(a,o)}else if(Ft(e))Ps(a,e.bind(n));else if(ln(e))if(Rt(e))e.forEach(o=>ON(o,t,n,r));else{const o=Ft(e.handler)?e.handler.bind(n):t[e.handler];Ft(o)&&Ps(a,o,e)}}function Tc(e){const t=e.type,{mixins:n,extends:r}=t,{mixins:a,optionsCache:o,config:{optionMergeStrategies:l}}=e.appContext,u=o.get(t);let c;return u?c=u:!a.length&&!n&&!r?Sn("PRIVATE_APIS",e)?(c=sn({},t),c.parent=e.parent&&e.parent.proxy,c.propsData=e.vnode.props):c=t:(c={},a.length&&a.forEach(d=>Bs(c,d,l,!0)),Bs(c,t,l)),ln(t)&&o.set(t,c),c}function Bs(e,t,n,r=!1){Ft(t)&&(t=t.options);const{mixins:a,extends:o}=t;o&&Bs(e,o,n,!0),a&&a.forEach(l=>Bs(e,l,n,!0));for(const l in t)if(!(r&&l==="expose")){const u=Us[l]||n&&n[l];e[l]=u?u(e[l],t[l]):t[l]}return e}const Us={data:DC,props:xC,emits:xC,methods:Cl,computed:Cl,beforeCreate:Xr,created:Xr,beforeMount:Xr,mounted:Xr,beforeUpdate:Xr,updated:Xr,beforeDestroy:Xr,beforeUnmount:Xr,destroyed:Xr,unmounted:Xr,activated:Xr,deactivated:Xr,errorCaptured:Xr,serverPrefetch:Xr,components:Cl,directives:Cl,watch:SG,provide:DC,inject:EG};Us.filters=Cl;function DC(e,t){return t?e?function(){return(Sn("OPTIONS_DATA_MERGE",null)?yN:sn)(Ft(e)?e.call(this,this):e,Ft(t)?t.call(this,this):t)}:t:e}function EG(e,t){return Cl(qh(e),qh(t))}function qh(e){if(Rt(e)){const t={};for(let n=0;n<e.length;n++)t[e[n]]=e[n];return t}return e}function Xr(e,t){return e?[...new Set([].concat(e,t))]:t}function Cl(e,t){return e?sn(Object.create(null),e,t):t}function xC(e,t){return e?Rt(e)&&Rt(t)?[...new Set([...e,...t])]:sn(Object.create(null),ic(e),ic(t!=null?t:{})):t}function SG(e,t){if(!e)return t;if(!t)return e;const n=sn(Object.create(null),e);for(const r in t)n[r]=Xr(e[r],t[r]);return n}function bG(e){e.optionMergeStrategies=new Proxy({},{get(t,n){if(n in t)return t[n];if(n in Us&&yo("CONFIG_OPTION_MERGE_STRATS",null))return Us[n]}})}let Si,Os;function vG(e,t){Si=t({});const n=Os=function c(d={}){return r(d,c)};function r(c={},d){Ir("GLOBAL_MOUNT",null);const{data:S}=c;S&&!Ft(S)&&yo("OPTIONS_DATA_FN",null)&&(c.data=()=>S);const _=e(c);d!==n&&RN(_,d);const E=_._createRoot(c);return c.el?E.$mount(c.el):E}n.version="2.6.14-compat:3.3.8",n.config=Si.config,n.use=(c,...d)=>(c&&Ft(c.install)?c.install(n,...d):Ft(c)&&c(n,...d),n),n.mixin=c=>(Si.mixin(c),n),n.component=(c,d)=>d?(Si.component(c,d),n):Si.component(c),n.directive=(c,d)=>d?(Si.directive(c,d),n):Si.directive(c),n.options={_base:n};let a=1;n.cid=a,n.nextTick=Ec;const o=new WeakMap;function l(c={}){if(Ir("GLOBAL_EXTEND",null),Ft(c)&&(c=c.options),o.has(c))return o.get(c);const d=this;function S(E){return r(E?Bs(sn({},S.options),E,Us):S.options,S)}S.super=d,S.prototype=Object.create(n.prototype),S.prototype.constructor=S;const _={};for(const E in d.options){const T=d.options[E];_[E]=Rt(T)?T.slice():ln(T)?sn(Object.create(null),T):T}return S.options=Bs(_,c,Us),S.options._base=S,S.extend=l.bind(S),S.mixin=d.mixin,S.use=d.use,S.cid=++a,o.set(c,S),S}n.extend=l.bind(n),n.set=(c,d,S)=>{Ir("GLOBAL_SET",null),c[d]=S},n.delete=(c,d)=>{Ir("GLOBAL_DELETE",null),delete c[d]},n.observable=c=>(Ir("GLOBAL_OBSERVABLE",null),ls(c)),n.filter=(c,d)=>d?(Si.filter(c,d),n):Si.filter(c);const u={warn:vi,extend:sn,mergeOptions:(c,d,S)=>Bs(c,d,S?void 0:Us),defineReactive:IG};return Object.defineProperty(n,"util",{get(){return Ir("GLOBAL_PRIVATE_UTIL",null),u}}),n.configureCompat=d3,n}function TG(e,t,n){yG(e,t),bG(e.config),Si&&(OG(e,t,n),CG(e),AG(e))}function yG(e,t){t.filters={},e.filter=(n,r)=>(Ir("FILTERS",null),r?(t.filters[n]=r,e):t.filters[n])}function CG(e){Object.defineProperties(e,{prototype:{get(){return e.config.globalProperties}},nextTick:{value:Ec},extend:{value:Os.extend},set:{value:Os.set},delete:{value:Os.delete},observable:{value:Os.observable},util:{get(){return Os.util}}})}function AG(e){e._context.mixins=[...Si._context.mixins],["components","directives","filters"].forEach(t=>{e._context[t]=Object.create(Si._context[t])});for(const t in Si.config){if(t==="isNativeTag"||$h()&&(t==="isCustomElement"||t==="compilerOptions"))continue;const n=Si.config[t];e.config[t]=ln(n)?Object.create(n):n,t==="ignoredElements"&&Sn("CONFIG_IGNORED_ELEMENTS",null)&&!$h()&&Rt(n)&&(e.config.compilerOptions.isCustomElement=r=>n.some(a=>xn(a)?a===r:a.test(r)))}RN(e,Os)}function RN(e,t){const n=Sn("GLOBAL_PROTOTYPE",null);n&&(e.config.globalProperties=Object.create(t.prototype));const r=Object.getOwnPropertyDescriptors(t.prototype);for(const a in r)a!=="constructor"&&n&&Object.defineProperty(e.config.globalProperties,a,r[a])}function OG(e,t,n){let r=!1;e._createRoot=a=>{const o=e._component,l=En(o,a.propsData||null);l.appContext=t;const u=!Ft(o)&&!o.render&&!o.template,c=()=>{},d=SS(l,null,null);return u&&(d.render=c),vS(d),l.component=d,l.isCompatRoot=!0,d.ctx._compat_mount=S=>{if(r)return;let _;if(typeof S=="string"){const T=document.querySelector(S);if(!T)return;_=T}else _=S||document.createElement("div");const E=_ instanceof SVGElement;return u&&d.render===c&&(d.render=null,o.template=_.innerHTML,TS(d,!1,!0)),_.innerHTML="",n(l,_,E),_ instanceof Element&&(_.removeAttribute("v-cloak"),_.setAttribute("data-v-app","")),r=!0,e._container=_,_.__vue_app__=e,d.proxy},d.ctx._compat_destroy=()=>{if(r)n(null,e._container),delete e._container.__vue_app__;else{const{bum:S,scope:_,um:E}=d;S&&Jo(S),Sn("INSTANCE_EVENT_HOOKS",d)&&d.emit("hook:beforeDestroy"),_&&_.stop(),E&&Jo(E),Sn("INSTANCE_EVENT_HOOKS",d)&&d.emit("hook:destroyed")}},d.proxy}}const RG=["push","pop","shift","unshift","splice","sort","reverse"],NG=new WeakSet;function IG(e,t,n){if(ln(n)&&!So(n)&&!NG.has(n)){const a=ls(n);Rt(n)?RG.forEach(o=>{n[o]=(...l)=>{Array.prototype[o].call(a,...l)}}):Object.keys(n).forEach(o=>{try{ah(n,o,n[o])}catch{}})}const r=e.$;r&&e===r.proxy?(ah(r.ctx,t,n),r.accessCache=Object.create(null)):So(e)?e[t]=n:ah(e,t,n)}function ah(e,t,n){n=ln(n)?ls(n):n,Object.defineProperty(e,t,{enumerable:!0,configurable:!0,get(){return ri(e,"get",t),n},set(r){n=ln(r)?ls(r):r,qa(e,"set",t,r)}})}function NN(){return{app:null,config:{isNativeTag:rU,performance:!1,globalProperties:{},optionMergeStrategies:{},errorHandler:void 0,warnHandler:void 0,compilerOptions:{}},mixins:[],components:{},directives:{},provides:Object.create(null),optionsCache:new WeakMap,propsCache:new WeakMap,emitsCache:new WeakMap}}let DG=0;function xG(e,t){return function(r,a=null){Ft(r)||(r=sn({},r)),a!=null&&!ln(a)&&(a=null);const o=NN(),l=new WeakSet;let u=!1;const c=o.app={_uid:DG++,_component:r,_props:a,_container:null,_context:o,_instance:null,version:ZN,get config(){return o.config},set config(d){},use(d,...S){return l.has(d)||(d&&Ft(d.install)?(l.add(d),d.install(c,...S)):Ft(d)&&(l.add(d),d(c,...S))),c},mixin(d){return o.mixins.includes(d)||o.mixins.push(d),c},component(d,S){return S?(o.components[d]=S,c):o.components[d]},directive(d,S){return S?(o.directives[d]=S,c):o.directives[d]},mount(d,S,_){if(!u){const E=En(r,a);return E.appContext=o,S&&t?t(E,d):e(E,d,_),u=!0,c._container=d,d.__vue_app__=c,Lf(E.component)||E.component.proxy}},unmount(){u&&(e(null,c._container),delete c._container.__vue_app__)},provide(d,S){return o.provides[d]=S,c},runWithContext(d){ac=c;try{return d()}finally{ac=null}}};return TG(c,o,e),c}}let ac=null;function IN(e,t){if(Xn){let n=Xn.provides;const r=Xn.parent&&Xn.parent.provides;r===n&&(n=Xn.provides=Object.create(r)),n[e]=t}}function Gs(e,t,n=!1){const r=Xn||Yn;if(r||ac){const a=r?r.parent==null?r.vnode.appContext&&r.vnode.appContext.provides:r.parent.provides:ac._context.provides;if(a&&e in a)return a[e];if(arguments.length>1)return n&&Ft(t)?t.call(r&&r.proxy):t}}function wG(){return!!(Xn||Yn||ac)}function LG(e,t,n){return new Proxy({},{get(r,a){if(a==="$options")return Tc(e);if(a in t)return t[a];const o=e.type.inject;if(o){if(Rt(o)){if(o.includes(a))return Gs(a)}else if(a in o)return Gs(a)}}})}function DN(e,t){return!!(e==="is"||(e==="class"||e==="style")&&Sn("INSTANCE_ATTRS_CLASS_STYLE",t)||Co(e)&&Sn("INSTANCE_LISTENERS",t)||e.startsWith("routerView")||e==="registerRouteInstance")}function MG(e,t,n,r=!1){const a={},o={};Ad(o,Df,1),e.propsDefaults=Object.create(null),xN(e,t,a,o);for(const l in e.propsOptions[0])l in a||(a[l]=void 0);n?e.props=r?a:PR(a):e.type.props?e.props=a:e.props=o,e.attrs=o}function kG(e,t,n,r){const{props:a,attrs:o,vnode:{patchFlag:l}}=e,u=pn(a),[c]=e.propsOptions;let d=!1;if((r||l>0)&&!(l&16)){if(l&8){const S=e.vnode.dynamicProps;for(let _=0;_<S.length;_++){let E=S[_];if(Af(e.emitsOptions,E))continue;const T=t[E];if(c)if(_n(o,E))T!==o[E]&&(o[E]=T,d=!0);else{const y=ni(E);a[y]=Yh(c,u,y,T,e,!1)}else{if(Co(E)&&E.endsWith("Native"))E=E.slice(0,-6);else if(DN(E,e))continue;T!==o[E]&&(o[E]=T,d=!0)}}}}else{xN(e,t,a,o)&&(d=!0);let S;for(const _ in u)(!t||!_n(t,_)&&((S=ei(_))===_||!_n(t,S)))&&(c?n&&(n[_]!==void 0||n[S]!==void 0)&&(a[_]=Yh(c,u,_,void 0,e,!0)):delete a[_]);if(o!==u)for(const _ in o)(!t||!_n(t,_)&&!_n(t,_+"Native"))&&(delete o[_],d=!0)}d&&qa(e,"set","$attrs")}function xN(e,t,n,r){const[a,o]=e.propsOptions;let l=!1,u;if(t)for(let c in t){if(Nl(c)||(c.startsWith("onHook:")&&yo("INSTANCE_EVENT_HOOKS",e,c.slice(2).toLowerCase()),c==="inline-template"))continue;const d=t[c];let S;if(a&&_n(a,S=ni(c)))!o||!o.includes(S)?n[S]=d:(u||(u={}))[S]=d;else if(!Af(e.emitsOptions,c)){if(Co(c)&&c.endsWith("Native"))c=c.slice(0,-6);else if(DN(c,e))continue;(!(c in r)||d!==r[c])&&(r[c]=d,l=!0)}}if(o){const c=pn(n),d=u||yn;for(let S=0;S<o.length;S++){const _=o[S];n[_]=Yh(a,c,_,d[_],e,!_n(d,_))}}return l}function Yh(e,t,n,r,a,o){const l=e[n];if(l!=null){const u=_n(l,"default");if(u&&r===void 0){const c=l.default;if(l.type!==Function&&!l.skipFactory&&Ft(c)){const{propsDefaults:d}=a;n in d?r=d[n]:(us(a),r=d[n]=c.call(Sn("PROPS_DEFAULT_THIS",a)?LG(a,t):null,t),ts())}else r=c}l[0]&&(o&&!u?r=!1:l[1]&&(r===""||r===ei(n))&&(r=!0))}return r}function wN(e,t,n=!1){const r=t.propsCache,a=r.get(e);if(a)return a;const o=e.props,l={},u=[];let c=!1;if(!Ft(e)){const S=_=>{Ft(_)&&(_=_.options),c=!0;const[E,T]=wN(_,t,!0);sn(l,E),T&&u.push(...T)};!n&&t.mixins.length&&t.mixins.forEach(S),e.extends&&S(e.extends),e.mixins&&e.mixins.forEach(S)}if(!o&&!c)return ln(e)&&r.set(e,Ol),Ol;if(Rt(o))for(let S=0;S<o.length;S++){const _=ni(o[S]);wC(_)&&(l[_]=yn)}else if(o)for(const S in o){const _=ni(S);if(wC(_)){const E=o[S],T=l[_]=Rt(E)||Ft(E)?{type:E}:sn({},E);if(T){const y=kC(Boolean,T.type),M=kC(String,T.type);T[0]=y>-1,T[1]=M<0||y<M,(y>-1||_n(T,"default"))&&u.push(_)}}}const d=[l,u];return ln(e)&&r.set(e,d),d}function wC(e){return e[0]!=="$"}function LC(e){const t=e&&e.toString().match(/^\s*(function|class) (\w+)/);return t?t[2]:e===null?"null":""}function MC(e,t){return LC(e)===LC(t)}function kC(e,t){return Rt(t)?t.findIndex(n=>MC(n,e)):Ft(t)&&MC(t,e)?0:-1}const LN=e=>e[0]==="_"||e==="$stable",mS=e=>Rt(e)?e.map(Pi):[Pi(e)],PG=(e,t,n)=>{if(t._n)return t;const r=sS((...a)=>mS(t(...a)),n);return r._c=!1,r},MN=(e,t,n)=>{const r=e._ctx;for(const a in e){if(LN(a))continue;const o=e[a];if(Ft(o))t[a]=PG(a,o,r);else if(o!=null){const l=mS(o);t[a]=()=>l}}},kN=(e,t)=>{const n=mS(t);e.slots.default=()=>n},FG=(e,t)=>{if(e.vnode.shapeFlag&32){const n=t._;n?(e.slots=pn(t),Ad(t,"_",n)):MN(t,e.slots={})}else e.slots={},t&&kN(e,t);Ad(e.slots,Df,1)},BG=(e,t,n)=>{const{vnode:r,slots:a}=e;let o=!0,l=yn;if(r.shapeFlag&32){const u=t._;u?n&&u===1?o=!1:(sn(a,t),!n&&u===1&&delete a._):(o=!t.$stable,MN(t,a)),l=t}else t&&(kN(e,t),l={default:1});if(o)for(const u in a)!LN(u)&&l[u]==null&&delete a[u]};function wd(e,t,n,r,a=!1){if(Rt(e)){e.forEach((E,T)=>wd(E,t&&(Rt(t)?t[T]:t),n,r,a));return}if(Fs(r)&&!a)return;const o=r.shapeFlag&4?Lf(r.component)||r.component.proxy:r.el,l=a?null:o,{i:u,r:c}=e,d=t&&t.r,S=u.refs===yn?u.refs={}:u.refs,_=u.setupState;if(d!=null&&d!==c&&(xn(d)?(S[d]=null,_n(_,d)&&(_[d]=null)):sr(d)&&(d.value=null)),Ft(c))Ya(c,u,12,[l,S]);else{const E=xn(c),T=sr(c);if(E||T){const y=()=>{if(e.f){const M=E?_n(_,c)?_[c]:S[c]:c.value;a?Rt(M)&&WE(M,o):Rt(M)?M.includes(o)||M.push(o):E?(S[c]=[o],_n(_,c)&&(_[c]=S[c])):(c.value=[o],e.k&&(S[e.k]=c.value))}else E?(S[c]=l,_n(_,c)&&(_[c]=l)):T&&(c.value=l,e.k&&(S[e.k]=l))};l?(y.id=-1,$n(y,n)):y()}}}let Wo=!1;const od=e=>/svg/.test(e.namespaceURI)&&e.tagName!=="foreignObject",sd=e=>e.nodeType===8;function UG(e){const{mt:t,p:n,o:{patchProp:r,createText:a,nextSibling:o,parentNode:l,remove:u,insert:c,createComment:d}}=e,S=(N,R)=>{if(!R.hasChildNodes()){n(null,N,R),Dd(),R._vnode=N;return}Wo=!1,_(R.firstChild,N,null,null,null),Dd(),R._vnode=N,Wo&&console.error("Hydration completed but contains mismatches.")},_=(N,R,L,I,h,k=!1)=>{const F=sd(N)&&N.data==="[",z=()=>M(N,R,L,I,h,F),{type:K,ref:ue,shapeFlag:Z,patchFlag:fe}=R;let V=N.nodeType;R.el=N,fe===-2&&(k=!1,R.dynamicChildren=null);let ne=null;switch(K){case js:V!==3?R.children===""?(c(R.el=a(""),l(N),N),ne=N):ne=z():(N.data!==R.children&&(Wo=!0,N.data=R.children),ne=o(N));break;case Dr:O(N)?(ne=o(N),A(R.el=N.content.firstChild,N,L)):V!==8||F?ne=z():ne=o(N);break;case Hs:if(F&&(N=o(N),V=N.nodeType),V===1||V===3){ne=N;const te=!R.children.length;for(let G=0;G<R.staticCount;G++)te&&(R.children+=ne.nodeType===1?ne.outerHTML:ne.data),G===R.staticCount-1&&(R.anchor=ne),ne=o(ne);return F?o(ne):ne}else z();break;case hr:F?ne=y(N,R,L,I,h,k):ne=z();break;default:if(Z&1)(V!==1||R.type.toLowerCase()!==N.tagName.toLowerCase())&&!O(N)?ne=z():ne=E(N,R,L,I,h,k);else if(Z&6){R.slotScopeIds=h;const te=l(N);if(F?ne=v(N):sd(N)&&N.data==="teleport start"?ne=v(N,N.data,"teleport end"):ne=o(N),t(R,te,null,L,I,od(te),k),Fs(R)){let G;F?(G=En(hr),G.anchor=ne?ne.previousSibling:te.lastChild):G=N.nodeType===3?ql(""):En("div"),G.el=N,R.component.subTree=G}}else Z&64?V!==8?ne=z():ne=R.type.hydrate(N,R,L,I,h,k,e,T):Z&128&&(ne=R.type.hydrate(N,R,L,I,od(l(N)),h,k,e,_))}return ue!=null&&wd(ue,null,I,R),ne},E=(N,R,L,I,h,k)=>{k=k||!!R.dynamicChildren;const{type:F,props:z,patchFlag:K,shapeFlag:ue,dirs:Z,transition:fe}=R,V=F==="input"&&Z||F==="option";if(V||K!==-1){if(Z&&Ba(R,null,L,"created"),z)if(V||!k||K&48)for(const G in z)(V&&G.endsWith("value")||Co(G)&&!Nl(G))&&r(N,G,null,z[G],!1,void 0,L);else z.onClick&&r(N,"onClick",null,z.onClick,!1,void 0,L);let ne;(ne=z&&z.onVnodeBeforeMount)&&Ei(ne,L,R);let te=!1;if(O(N)){te=UN(I,fe)&&L&&L.vnode.props&&L.vnode.props.appear;const G=N.content.firstChild;te&&fe.beforeEnter(G),A(G,N,L),R.el=N=G}if(Z&&Ba(R,null,L,"beforeMount"),((ne=z&&z.onVnodeMounted)||Z||te)&&jR(()=>{ne&&Ei(ne,L,R),te&&fe.enter(N),Z&&Ba(R,null,L,"mounted")},I),ue&16&&!(z&&(z.innerHTML||z.textContent))){let G=T(N.firstChild,R,N,L,I,h,k);for(;G;){Wo=!0;const se=G;G=G.nextSibling,u(se)}}else ue&8&&N.textContent!==R.children&&(Wo=!0,N.textContent=R.children)}return N.nextSibling},T=(N,R,L,I,h,k,F)=>{F=F||!!R.dynamicChildren;const z=R.children,K=z.length;for(let ue=0;ue<K;ue++){const Z=F?z[ue]:z[ue]=Pi(z[ue]);if(N)N=_(N,Z,I,h,k,F);else{if(Z.type===js&&!Z.children)continue;Wo=!0,n(null,Z,L,null,I,h,od(L),k)}}return N},y=(N,R,L,I,h,k)=>{const{slotScopeIds:F}=R;F&&(h=h?h.concat(F):F);const z=l(N),K=T(o(N),R,z,L,I,h,k);return K&&sd(K)&&K.data==="]"?o(R.anchor=K):(Wo=!0,c(R.anchor=d("]"),z,K),K)},M=(N,R,L,I,h,k)=>{if(Wo=!0,R.el=null,k){const K=v(N);for(;;){const ue=o(N);if(ue&&ue!==K)u(ue);else break}}const F=o(N),z=l(N);return u(N),n(null,R,z,F,L,I,od(z),h),F},v=(N,R="[",L="]")=>{let I=0;for(;N;)if(N=o(N),N&&sd(N)&&(N.data===R&&I++,N.data===L)){if(I===0)return o(N);I--}return N},A=(N,R,L)=>{const I=R.parentNode;I&&I.replaceChild(N,R);let h=L;for(;h;)h.vnode.el===R&&(h.vnode.el=h.subTree.el=N),h=h.parent},O=N=>N.nodeType===1&&N.tagName.toLowerCase()==="template";return[S,_]}const $n=jR;function PN(e){return BN(e)}function FN(e){return BN(e,UG)}function BN(e,t){const n=Lh();n.__VUE__=!0;const{insert:r,remove:a,patchProp:o,createElement:l,createText:u,createComment:c,setText:d,setElementText:S,parentNode:_,nextSibling:E,setScopeId:T=vi,insertStaticContent:y}=e,M=(ce,Ee,He,we=null,ze=null,pe=null,Re=!1,Ne=null,Ie=!!Ee.dynamicChildren)=>{if(ce===Ee)return;ce&&!ba(ce,Ee)&&(we=bt(ce),oe(ce,ze,pe,!0),ce=null),Ee.patchFlag===-2&&(Ie=!1,Ee.dynamicChildren=null);const{type:Ue,ref:Ve,shapeFlag:lt}=Ee;switch(Ue){case js:v(ce,Ee,He,we);break;case Dr:A(ce,Ee,He,we);break;case Hs:ce==null&&O(Ee,He,we,Re);break;case hr:ue(ce,Ee,He,we,ze,pe,Re,Ne,Ie);break;default:lt&1?L(ce,Ee,He,we,ze,pe,Re,Ne,Ie):lt&6?Z(ce,Ee,He,we,ze,pe,Re,Ne,Ie):(lt&64||lt&128)&&Ue.process(ce,Ee,He,we,ze,pe,Re,Ne,Ie,ct)}Ve!=null&&ze&&wd(Ve,ce&&ce.ref,pe,Ee||ce,!Ee)},v=(ce,Ee,He,we)=>{if(ce==null)r(Ee.el=u(Ee.children),He,we);else{const ze=Ee.el=ce.el;Ee.children!==ce.children&&d(ze,Ee.children)}},A=(ce,Ee,He,we)=>{ce==null?r(Ee.el=c(Ee.children||""),He,we):Ee.el=ce.el},O=(ce,Ee,He,we)=>{[ce.el,ce.anchor]=y(ce.children,Ee,He,we,ce.el,ce.anchor)},N=({el:ce,anchor:Ee},He,we)=>{let ze;for(;ce&&ce!==Ee;)ze=E(ce),r(ce,He,we),ce=ze;r(Ee,He,we)},R=({el:ce,anchor:Ee})=>{let He;for(;ce&&ce!==Ee;)He=E(ce),a(ce),ce=He;a(Ee)},L=(ce,Ee,He,we,ze,pe,Re,Ne,Ie)=>{Re=Re||Ee.type==="svg",ce==null?I(Ee,He,we,ze,pe,Re,Ne,Ie):F(ce,Ee,ze,pe,Re,Ne,Ie)},I=(ce,Ee,He,we,ze,pe,Re,Ne)=>{let Ie,Ue;const{type:Ve,props:lt,shapeFlag:ge,transition:de,dirs:be}=ce;if(Ie=ce.el=l(ce.type,pe,lt&<.is,lt),ge&8?S(Ie,ce.children):ge&16&&k(ce.children,Ie,null,we,ze,pe&&Ve!=="foreignObject",Re,Ne),be&&Ba(ce,null,we,"created"),h(Ie,ce,ce.scopeId,Re,we),lt){for(const ee in lt)ee!=="value"&&!Nl(ee)&&o(Ie,ee,null,lt[ee],pe,ce.children,we,ze,rt);"value"in lt&&o(Ie,"value",null,lt.value),(Ue=lt.onVnodeBeforeMount)&&Ei(Ue,we,ce)}be&&Ba(ce,null,we,"beforeMount");const H=UN(ze,de);H&&de.beforeEnter(Ie),r(Ie,Ee,He),((Ue=lt&<.onVnodeMounted)||H||be)&&$n(()=>{Ue&&Ei(Ue,we,ce),H&&de.enter(Ie),be&&Ba(ce,null,we,"mounted")},ze)},h=(ce,Ee,He,we,ze)=>{if(He&&T(ce,He),we)for(let pe=0;pe<we.length;pe++)T(ce,we[pe]);if(ze){let pe=ze.subTree;if(Ee===pe){const Re=ze.vnode;h(ce,Re,Re.scopeId,Re.slotScopeIds,ze.parent)}}},k=(ce,Ee,He,we,ze,pe,Re,Ne,Ie=0)=>{for(let Ue=Ie;Ue<ce.length;Ue++){const Ve=ce[Ue]=Ne?$o(ce[Ue]):Pi(ce[Ue]);M(null,Ve,Ee,He,we,ze,pe,Re,Ne)}},F=(ce,Ee,He,we,ze,pe,Re)=>{const Ne=Ee.el=ce.el;let{patchFlag:Ie,dynamicChildren:Ue,dirs:Ve}=Ee;Ie|=ce.patchFlag&16;const lt=ce.props||yn,ge=Ee.props||yn;let de;He&&vs(He,!1),(de=ge.onVnodeBeforeUpdate)&&Ei(de,He,Ee,ce),Ve&&Ba(Ee,ce,He,"beforeUpdate"),He&&vs(He,!0);const be=ze&&Ee.type!=="foreignObject";if(Ue?z(ce.dynamicChildren,Ue,Ne,He,we,be,pe):Re||G(ce,Ee,Ne,null,He,we,be,pe,!1),Ie>0){if(Ie&16)K(Ne,Ee,lt,ge,He,we,ze);else if(Ie&2&<.class!==ge.class&&o(Ne,"class",null,ge.class,ze),Ie&4&&o(Ne,"style",lt.style,ge.style,ze),Ie&8){const H=Ee.dynamicProps;for(let ee=0;ee<H.length;ee++){const _e=H[ee],U=lt[_e],Q=ge[_e];(Q!==U||_e==="value")&&o(Ne,_e,U,Q,ze,ce.children,He,we,rt)}}Ie&1&&ce.children!==Ee.children&&S(Ne,Ee.children)}else!Re&&Ue==null&&K(Ne,Ee,lt,ge,He,we,ze);((de=ge.onVnodeUpdated)||Ve)&&$n(()=>{de&&Ei(de,He,Ee,ce),Ve&&Ba(Ee,ce,He,"updated")},we)},z=(ce,Ee,He,we,ze,pe,Re)=>{for(let Ne=0;Ne<Ee.length;Ne++){const Ie=ce[Ne],Ue=Ee[Ne],Ve=Ie.el&&(Ie.type===hr||!ba(Ie,Ue)||Ie.shapeFlag&70)?_(Ie.el):He;M(Ie,Ue,Ve,null,we,ze,pe,Re,!0)}},K=(ce,Ee,He,we,ze,pe,Re)=>{if(He!==we){if(He!==yn)for(const Ne in He)!Nl(Ne)&&!(Ne in we)&&o(ce,Ne,He[Ne],null,Re,Ee.children,ze,pe,rt);for(const Ne in we){if(Nl(Ne))continue;const Ie=we[Ne],Ue=He[Ne];Ie!==Ue&&Ne!=="value"&&o(ce,Ne,Ue,Ie,Re,Ee.children,ze,pe,rt)}"value"in we&&o(ce,"value",He.value,we.value)}},ue=(ce,Ee,He,we,ze,pe,Re,Ne,Ie)=>{const Ue=Ee.el=ce?ce.el:u(""),Ve=Ee.anchor=ce?ce.anchor:u("");let{patchFlag:lt,dynamicChildren:ge,slotScopeIds:de}=Ee;de&&(Ne=Ne?Ne.concat(de):de),ce==null?(r(Ue,He,we),r(Ve,He,we),k(Ee.children,He,Ve,ze,pe,Re,Ne,Ie)):lt>0&<&64&&ge&&ce.dynamicChildren?(z(ce.dynamicChildren,ge,He,ze,pe,Re,Ne),(Ee.key!=null||ze&&Ee===ze.subTree)&&gS(ce,Ee,!0)):G(ce,Ee,He,Ve,ze,pe,Re,Ne,Ie)},Z=(ce,Ee,He,we,ze,pe,Re,Ne,Ie)=>{Ee.slotScopeIds=Ne,ce==null?Ee.shapeFlag&512?ze.ctx.activate(Ee,He,we,Re,Ie):fe(Ee,He,we,ze,pe,Re,Ie):V(ce,Ee,Ie)},fe=(ce,Ee,He,we,ze,pe,Re)=>{const Ne=ce.isCompatRoot&&ce.component,Ie=Ne||(ce.component=SS(ce,we,ze));if(bc(ce)&&(Ie.ctx.renderer=ct),Ne||vS(Ie),Ie.asyncDep){if(ze&&ze.registerDep(Ie,ne),!ce.el){const Ue=Ie.subTree=En(Dr);A(null,Ue,Ee,He)}return}ne(Ie,ce,Ee,He,ze,pe,Re)},V=(ce,Ee,He)=>{const we=Ee.component=ce.component;if(y3(ce,Ee,He))if(we.asyncDep&&!we.asyncResolved){te(we,Ee,He);return}else we.next=Ee,l3(we.update),we.update();else Ee.el=ce.el,we.vnode=Ee},ne=(ce,Ee,He,we,ze,pe,Re)=>{const Ne=()=>{if(ce.isMounted){let{next:Ve,bu:lt,u:ge,parent:de,vnode:be}=ce,H=Ve,ee;vs(ce,!1),Ve?(Ve.el=be.el,te(ce,Ve,Re)):Ve=be,lt&&Jo(lt),(ee=Ve.props&&Ve.props.onVnodeBeforeUpdate)&&Ei(ee,de,Ve,be),Sn("INSTANCE_EVENT_HOOKS",ce)&&ce.emit("hook:beforeUpdate"),vs(ce,!0);const _e=pd(ce),U=ce.subTree;ce.subTree=_e,M(U,_e,_(U.el),bt(U),ce,ze,pe),Ve.el=_e.el,H===null&&lS(ce,_e.el),ge&&$n(ge,ze),(ee=Ve.props&&Ve.props.onVnodeUpdated)&&$n(()=>Ei(ee,de,Ve,be),ze),Sn("INSTANCE_EVENT_HOOKS",ce)&&$n(()=>ce.emit("hook:updated"),ze)}else{let Ve;const{el:lt,props:ge}=Ee,{bm:de,m:be,parent:H}=ce,ee=Fs(Ee);if(vs(ce,!1),de&&Jo(de),!ee&&(Ve=ge&&ge.onVnodeBeforeMount)&&Ei(Ve,H,Ee),Sn("INSTANCE_EVENT_HOOKS",ce)&&ce.emit("hook:beforeMount"),vs(ce,!0),lt&&nt){const _e=()=>{ce.subTree=pd(ce),nt(lt,ce.subTree,ce,ze,null)};ee?Ee.type.__asyncLoader().then(()=>!ce.isUnmounted&&_e()):_e()}else{const _e=ce.subTree=pd(ce);M(null,_e,He,we,ce,ze,pe),Ee.el=_e.el}if(be&&$n(be,ze),!ee&&(Ve=ge&&ge.onVnodeMounted)){const _e=Ee;$n(()=>Ei(Ve,H,_e),ze)}Sn("INSTANCE_EVENT_HOOKS",ce)&&$n(()=>ce.emit("hook:mounted"),ze),(Ee.shapeFlag&256||H&&Fs(H.vnode)&&H.vnode.shapeFlag&256)&&(ce.a&&$n(ce.a,ze),Sn("INSTANCE_EVENT_HOOKS",ce)&&$n(()=>ce.emit("hook:activated"),ze)),ce.isMounted=!0,Ee=He=we=null}},Ie=ce.effect=new Gl(Ne,()=>Tf(Ue),ce.scope),Ue=ce.update=()=>Ie.run();Ue.id=ce.uid,vs(ce,!0),Ue()},te=(ce,Ee,He)=>{Ee.component=ce;const we=ce.vnode.props;ce.vnode=Ee,ce.next=null,kG(ce,Ee.props,we,He),BG(ce,Ee.children,He),nu(),SC(),ru()},G=(ce,Ee,He,we,ze,pe,Re,Ne,Ie=!1)=>{const Ue=ce&&ce.children,Ve=ce?ce.shapeFlag:0,lt=Ee.children,{patchFlag:ge,shapeFlag:de}=Ee;if(ge>0){if(ge&128){ve(Ue,lt,He,we,ze,pe,Re,Ne,Ie);return}else if(ge&256){se(Ue,lt,He,we,ze,pe,Re,Ne,Ie);return}}de&8?(Ve&16&&rt(Ue,ze,pe),lt!==Ue&&S(He,lt)):Ve&16?de&16?ve(Ue,lt,He,we,ze,pe,Re,Ne,Ie):rt(Ue,ze,pe,!0):(Ve&8&&S(He,""),de&16&&k(lt,He,we,ze,pe,Re,Ne,Ie))},se=(ce,Ee,He,we,ze,pe,Re,Ne,Ie)=>{ce=ce||Ol,Ee=Ee||Ol;const Ue=ce.length,Ve=Ee.length,lt=Math.min(Ue,Ve);let ge;for(ge=0;ge<lt;ge++){const de=Ee[ge]=Ie?$o(Ee[ge]):Pi(Ee[ge]);M(ce[ge],de,He,null,ze,pe,Re,Ne,Ie)}Ue>Ve?rt(ce,ze,pe,!0,!1,lt):k(Ee,He,we,ze,pe,Re,Ne,Ie,lt)},ve=(ce,Ee,He,we,ze,pe,Re,Ne,Ie)=>{let Ue=0;const Ve=Ee.length;let lt=ce.length-1,ge=Ve-1;for(;Ue<=lt&&Ue<=ge;){const de=ce[Ue],be=Ee[Ue]=Ie?$o(Ee[Ue]):Pi(Ee[Ue]);if(ba(de,be))M(de,be,He,null,ze,pe,Re,Ne,Ie);else break;Ue++}for(;Ue<=lt&&Ue<=ge;){const de=ce[lt],be=Ee[ge]=Ie?$o(Ee[ge]):Pi(Ee[ge]);if(ba(de,be))M(de,be,He,null,ze,pe,Re,Ne,Ie);else break;lt--,ge--}if(Ue>lt){if(Ue<=ge){const de=ge+1,be=de<Ve?Ee[de].el:we;for(;Ue<=ge;)M(null,Ee[Ue]=Ie?$o(Ee[Ue]):Pi(Ee[Ue]),He,be,ze,pe,Re,Ne,Ie),Ue++}}else if(Ue>ge)for(;Ue<=lt;)oe(ce[Ue],ze,pe,!0),Ue++;else{const de=Ue,be=Ue,H=new Map;for(Ue=be;Ue<=ge;Ue++){const je=Ee[Ue]=Ie?$o(Ee[Ue]):Pi(Ee[Ue]);je.key!=null&&H.set(je.key,Ue)}let ee,_e=0;const U=ge-be+1;let Q=!1,he=0;const Le=new Array(U);for(Ue=0;Ue<U;Ue++)Le[Ue]=0;for(Ue=de;Ue<=lt;Ue++){const je=ce[Ue];if(_e>=U){oe(je,ze,pe,!0);continue}let at;if(je.key!=null)at=H.get(je.key);else for(ee=be;ee<=ge;ee++)if(Le[ee-be]===0&&ba(je,Ee[ee])){at=ee;break}at===void 0?oe(je,ze,pe,!0):(Le[at-be]=Ue+1,at>=he?he=at:Q=!0,M(je,Ee[at],He,null,ze,pe,Re,Ne,Ie),_e++)}const Xe=Q?GG(Le):Ol;for(ee=Xe.length-1,Ue=U-1;Ue>=0;Ue--){const je=be+Ue,at=Ee[je],ke=je+1<Ve?Ee[je+1].el:we;Le[Ue]===0?M(null,at,He,ke,ze,pe,Re,Ne,Ie):Q&&(ee<0||Ue!==Xe[ee]?Ge(at,He,ke,2):ee--)}}},Ge=(ce,Ee,He,we,ze=null)=>{const{el:pe,type:Re,transition:Ne,children:Ie,shapeFlag:Ue}=ce;if(Ue&6){Ge(ce.component.subTree,Ee,He,we);return}if(Ue&128){ce.suspense.move(Ee,He,we);return}if(Ue&64){Re.move(ce,Ee,He,ct);return}if(Re===hr){r(pe,Ee,He);for(let lt=0;lt<Ie.length;lt++)Ge(Ie[lt],Ee,He,we);r(ce.anchor,Ee,He);return}if(Re===Hs){N(ce,Ee,He);return}if(we!==2&&Ue&1&&Ne)if(we===0)Ne.beforeEnter(pe),r(pe,Ee,He),$n(()=>Ne.enter(pe),ze);else{const{leave:lt,delayLeave:ge,afterLeave:de}=Ne,be=()=>r(pe,Ee,He),H=()=>{lt(pe,()=>{be(),de&&de()})};ge?ge(pe,be,H):H()}else r(pe,Ee,He)},oe=(ce,Ee,He,we=!1,ze=!1)=>{const{type:pe,props:Re,ref:Ne,children:Ie,dynamicChildren:Ue,shapeFlag:Ve,patchFlag:lt,dirs:ge}=ce;if(Ne!=null&&wd(Ne,null,He,ce,!0),Ve&256){Ee.ctx.deactivate(ce);return}const de=Ve&1&&ge,be=!Fs(ce);let H;if(be&&(H=Re&&Re.onVnodeBeforeUnmount)&&Ei(H,Ee,ce),Ve&6)tt(ce.component,He,we);else{if(Ve&128){ce.suspense.unmount(He,we);return}de&&Ba(ce,null,Ee,"beforeUnmount"),Ve&64?ce.type.remove(ce,Ee,He,ze,ct,we):Ue&&(pe!==hr||lt>0&<&64)?rt(Ue,Ee,He,!1,!0):(pe===hr&<&384||!ze&&Ve&16)&&rt(Ie,Ee,He),we&&W(ce)}(be&&(H=Re&&Re.onVnodeUnmounted)||de)&&$n(()=>{H&&Ei(H,Ee,ce),de&&Ba(ce,null,Ee,"unmounted")},He)},W=ce=>{const{type:Ee,el:He,anchor:we,transition:ze}=ce;if(Ee===hr){Oe(He,we);return}if(Ee===Hs){R(ce);return}const pe=()=>{a(He),ze&&!ze.persisted&&ze.afterLeave&&ze.afterLeave()};if(ce.shapeFlag&1&&ze&&!ze.persisted){const{leave:Re,delayLeave:Ne}=ze,Ie=()=>Re(He,pe);Ne?Ne(ce.el,pe,Ie):Ie()}else pe()},Oe=(ce,Ee)=>{let He;for(;ce!==Ee;)He=E(ce),a(ce),ce=He;a(Ee)},tt=(ce,Ee,He)=>{const{bum:we,scope:ze,update:pe,subTree:Re,um:Ne}=ce;we&&Jo(we),Sn("INSTANCE_EVENT_HOOKS",ce)&&ce.emit("hook:beforeDestroy"),ze.stop(),pe&&(pe.active=!1,oe(Re,ce,Ee,He)),Ne&&$n(Ne,Ee),Sn("INSTANCE_EVENT_HOOKS",ce)&&$n(()=>ce.emit("hook:destroyed"),Ee),$n(()=>{ce.isUnmounted=!0},Ee),Ee&&Ee.pendingBranch&&!Ee.isUnmounted&&ce.asyncDep&&!ce.asyncResolved&&ce.suspenseId===Ee.pendingId&&(Ee.deps--,Ee.deps===0&&Ee.resolve())},rt=(ce,Ee,He,we=!1,ze=!1,pe=0)=>{for(let Re=pe;Re<ce.length;Re++)oe(ce[Re],Ee,He,we,ze)},bt=ce=>ce.shapeFlag&6?bt(ce.component.subTree):ce.shapeFlag&128?ce.suspense.next():E(ce.anchor||ce.el),dt=(ce,Ee,He)=>{ce==null?Ee._vnode&&oe(Ee._vnode,null,null,!0):M(Ee._vnode||null,ce,Ee,null,null,null,He),SC(),Dd(),Ee._vnode=ce},ct={p:M,um:oe,m:Ge,r:W,mt:fe,mc:k,pc:G,pbc:z,n:bt,o:e};let Ze,nt;return t&&([Ze,nt]=t(ct)),{render:dt,hydrate:Ze,createApp:xG(dt,Ze)}}function vs({effect:e,update:t},n){e.allowRecurse=t.allowRecurse=n}function UN(e,t){return(!e||e&&!e.pendingBranch)&&t&&!t.persisted}function gS(e,t,n=!1){const r=e.children,a=t.children;if(Rt(r)&&Rt(a))for(let o=0;o<r.length;o++){const l=r[o];let u=a[o];u.shapeFlag&1&&!u.dynamicChildren&&((u.patchFlag<=0||u.patchFlag===32)&&(u=a[o]=$o(a[o]),u.el=l.el),n||gS(l,u)),u.type===js&&(u.el=l.el)}}function GG(e){const t=e.slice(),n=[0];let r,a,o,l,u;const c=e.length;for(r=0;r<c;r++){const d=e[r];if(d!==0){if(a=n[n.length-1],e[a]<d){t[r]=a,n.push(r);continue}for(o=0,l=n.length-1;o<l;)u=o+l>>1,e[n[u]]<d?o=u+1:l=u;d<e[n[o]]&&(o>0&&(t[r]=n[o-1]),n[o]=r)}}for(o=n.length,l=n[o-1];o-- >0;)n[o]=l,l=t[l];return n}const HG=e=>e.__isTeleport,Pu=e=>e&&(e.disabled||e.disabled===""),PC=e=>typeof SVGElement<"u"&&e instanceof SVGElement,Wh=(e,t)=>{const n=e&&e.to;return xn(n)?t?t(n):null:n},qG={__isTeleport:!0,process(e,t,n,r,a,o,l,u,c,d){const{mc:S,pc:_,pbc:E,o:{insert:T,querySelector:y,createText:M,createComment:v}}=d,A=Pu(t.props);let{shapeFlag:O,children:N,dynamicChildren:R}=t;if(e==null){const L=t.el=M(""),I=t.anchor=M("");T(L,n,r),T(I,n,r);const h=t.target=Wh(t.props,y),k=t.targetAnchor=M("");h&&(T(k,h),l=l||PC(h));const F=(z,K)=>{O&16&&S(N,z,K,a,o,l,u,c)};A?F(n,I):h&&F(h,k)}else{t.el=e.el;const L=t.anchor=e.anchor,I=t.target=e.target,h=t.targetAnchor=e.targetAnchor,k=Pu(e.props),F=k?n:I,z=k?L:h;if(l=l||PC(I),R?(E(e.dynamicChildren,R,F,a,o,l,u),gS(e,t,!0)):c||_(e,t,F,z,a,o,l,u,!1),A)k?t.props&&e.props&&t.props.to!==e.props.to&&(t.props.to=e.props.to):ld(t,n,L,d,1);else if((t.props&&t.props.to)!==(e.props&&e.props.to)){const K=t.target=Wh(t.props,y);K&&ld(t,K,null,d,0)}else k&&ld(t,I,h,d,1)}GN(t)},remove(e,t,n,r,{um:a,o:{remove:o}},l){const{shapeFlag:u,children:c,anchor:d,targetAnchor:S,target:_,props:E}=e;if(_&&o(S),l&&o(d),u&16){const T=l||!Pu(E);for(let y=0;y<c.length;y++){const M=c[y];a(M,t,n,T,!!M.dynamicChildren)}}},move:ld,hydrate:YG};function ld(e,t,n,{o:{insert:r},m:a},o=2){o===0&&r(e.targetAnchor,t,n);const{el:l,anchor:u,shapeFlag:c,children:d,props:S}=e,_=o===2;if(_&&r(l,t,n),(!_||Pu(S))&&c&16)for(let E=0;E<d.length;E++)a(d[E],t,n,2);_&&r(u,t,n)}function YG(e,t,n,r,a,o,{o:{nextSibling:l,parentNode:u,querySelector:c}},d){const S=t.target=Wh(t.props,c);if(S){const _=S._lpa||S.firstChild;if(t.shapeFlag&16)if(Pu(t.props))t.anchor=d(l(e),t,u(e),n,r,a,o),t.targetAnchor=_;else{t.anchor=l(e);let E=_;for(;E;)if(E=l(E),E&&E.nodeType===8&&E.data==="teleport anchor"){t.targetAnchor=E,S._lpa=t.targetAnchor&&l(t.targetAnchor);break}d(_,t,S,n,r,a,o)}GN(t)}return t.anchor&&l(t.anchor)}const WG=qG;function GN(e){const t=e.ctx;if(t&&t.ut){let n=e.children[0].el;for(;n&&n!==e.targetAnchor;)n.nodeType===1&&n.setAttribute("data-v-owner",t.uid),n=n.nextSibling;t.ut()}}const oh=new WeakMap;function VG(e){if(oh.has(e))return oh.get(e);let t,n;const r=new Promise((l,u)=>{t=l,n=u}),a=e(t,n);let o;return gf(a)?o=_d(()=>a):ln(a)&&!Bi(a)&&!Rt(a)?o=_d({loader:()=>a.component,loadingComponent:a.loading,errorComponent:a.error,delay:a.delay,timeout:a.timeout}):a==null?o=_d(()=>r):o=e,oh.set(e,o),o}function zG(e,t){return e.__isBuiltIn?e:(Ft(e)&&e.cid&&(e=e.options),Ft(e)&&yf("COMPONENT_ASYNC",t,e)?VG(e):ln(e)&&e.functional&&yo("COMPONENT_FUNCTIONAL",t,e)?W3(e):e)}const hr=Symbol.for("v-fgt"),js=Symbol.for("v-txt"),Dr=Symbol.for("v-cmt"),Hs=Symbol.for("v-stc"),Fu=[];let bi=null;function ki(e=!1){Fu.push(bi=e?null:[])}function HN(){Fu.pop(),bi=Fu[Fu.length-1]||null}let Xs=1;function Vh(e){Xs+=e}function qN(e){return e.dynamicChildren=Xs>0?bi||Ol:null,HN(),Xs>0&&bi&&bi.push(e),e}function Ma(e,t,n,r,a,o){return qN(on(e,t,n,r,a,o,!0))}function hS(e,t,n,r,a){return qN(En(e,t,n,r,a,!0))}function Bi(e){return e?e.__v_isVNode===!0:!1}function ba(e,t){return e.type===t.type&&e.key===t.key}function KG(e){}const Df="__vInternal",YN=({key:e})=>e!=null?e:null,md=({ref:e,ref_key:t,ref_for:n})=>(typeof e=="number"&&(e=""+e),e!=null?xn(e)||sr(e)||Ft(e)?{i:Yn,r:e,k:t,f:!!n}:e:null);function on(e,t=null,n=null,r=0,a=null,o=e===hr?0:1,l=!1,u=!1){const c={__v_isVNode:!0,__v_skip:!0,type:e,props:t,key:t&&YN(t),ref:t&&md(t),scopeId:wl,slotScopeIds:null,children:n,component:null,suspense:null,ssContent:null,ssFallback:null,dirs:null,transition:null,el:null,anchor:null,target:null,targetAnchor:null,staticCount:0,shapeFlag:o,patchFlag:r,dynamicProps:a,dynamicChildren:null,appContext:null,ctx:Yn};return u?(xf(c,n),o&128&&e.normalize(c)):n&&(c.shapeFlag|=xn(n)?8:16),Xs>0&&!l&&bi&&(c.patchFlag>0||o&6)&&c.patchFlag!==32&&bi.push(c),_3(c),gN(c),c}const En=$G;function $G(e,t=null,n=null,r=0,a=null,o=!1){if((!e||e===VR)&&(e=Dr),Bi(e)){const u=va(e,t,!0);return n&&xf(u,n),Xs>0&&!o&&bi&&(u.shapeFlag&6?bi[bi.indexOf(e)]=u:bi.push(u)),u.patchFlag|=-2,u}if(eH(e)&&(e=e.__vccOpts),e=zG(e,Yn),t){t=WN(t);let{class:u,style:c}=t;u&&!xn(u)&&(t.class=Va(u)),ln(c)&&(jE(c)&&!Rt(c)&&(c=sn({},c)),t.style=tu(c))}const l=xn(e)?1:QR(e)?128:HG(e)?64:ln(e)?4:Ft(e)?2:0;return on(e,t,n,r,a,l,o,!0)}function WN(e){return e?jE(e)||Df in e?sn({},e):e:null}function va(e,t,n=!1){const{props:r,ref:a,patchFlag:o,children:l}=e,u=t?wf(r||{},t):r,c={__v_isVNode:!0,__v_skip:!0,type:e.type,props:u,key:u&&YN(u),ref:t&&t.ref?n&&a?Rt(a)?a.concat(md(t)):[a,md(t)]:md(t):a,scopeId:e.scopeId,slotScopeIds:e.slotScopeIds,children:l,target:e.target,targetAnchor:e.targetAnchor,staticCount:e.staticCount,shapeFlag:e.shapeFlag,patchFlag:t&&e.type!==hr?o===-1?16:o|16:o,dynamicProps:e.dynamicProps,dynamicChildren:e.dynamicChildren,appContext:e.appContext,dirs:e.dirs,transition:e.transition,component:e.component,suspense:e.suspense,ssContent:e.ssContent&&va(e.ssContent),ssFallback:e.ssFallback&&va(e.ssFallback),el:e.el,anchor:e.anchor,ctx:e.ctx,ce:e.ce};return gN(c),c}function ql(e=" ",t=0){return En(js,null,e,t)}function ES(e,t){const n=En(Hs,null,e);return n.staticCount=t,n}function Ld(e="",t=!1){return t?(ki(),hS(Dr,null,e)):En(Dr,null,e)}function Pi(e){return e==null||typeof e=="boolean"?En(Dr):Rt(e)?En(hr,null,e.slice()):typeof e=="object"?$o(e):En(js,null,String(e))}function $o(e){return e.el===null&&e.patchFlag!==-1||e.memo?e:va(e)}function xf(e,t){let n=0;const{shapeFlag:r}=e;if(t==null)t=null;else if(Rt(t))n=16;else if(typeof t=="object")if(r&65){const a=t.default;a&&(a._c&&(a._d=!1),xf(e,a()),a._c&&(a._d=!0));return}else{n=32;const a=t._;!a&&!(Df in t)?t._ctx=Yn:a===3&&Yn&&(Yn.slots._===1?t._=1:(t._=2,e.patchFlag|=1024))}else Ft(t)?(t={default:t,_ctx:Yn},n=32):(t=String(t),r&64?(n=16,t=[ql(t)]):n=8);e.children=t,e.shapeFlag|=n}function wf(...e){const t={};for(let n=0;n<e.length;n++){const r=e[n];for(const a in r)if(a==="class")t.class!==r.class&&(t.class=Va([t.class,r.class]));else if(a==="style")t.style=tu([t.style,r.style]);else if(Co(a)){const o=t[a],l=r[a];l&&o!==l&&!(Rt(o)&&o.includes(l))&&(t[a]=o?[].concat(o,l):l)}else a!==""&&(t[a]=r[a])}return t}function Ei(e,t,n,r=null){Ti(e,t,7,[n,r])}const QG=NN();let jG=0;function SS(e,t,n){const r=e.type,a=(t?t.appContext:e.appContext)||QG,o={uid:jG++,vnode:e,type:r,parent:t,appContext:a,root:null,next:null,subTree:null,effect:null,update:null,scope:new zE(!0),render:null,proxy:null,exposed:null,exposeProxy:null,withProxy:null,provides:t?t.provides:Object.create(a.provides),accessCache:null,renderCache:[],components:null,directives:null,propsOptions:wN(r,a),emitsOptions:WR(r,a),emit:null,emitted:null,propsDefaults:yn,inheritAttrs:r.inheritAttrs,ctx:yn,data:yn,props:yn,attrs:yn,slots:yn,refs:yn,setupState:yn,setupContext:null,attrsProxy:null,slotsProxy:null,suspense:n,suspenseId:n?n.pendingId:0,asyncDep:null,asyncResolved:!1,isMounted:!1,isUnmounted:!1,isDeactivated:!1,bc:null,c:null,bm:null,m:null,bu:null,u:null,um:null,bum:null,da:null,a:null,rtg:null,rtc:null,ec:null,sp:null};return o.ctx={_:o},o.root=t?t.root:o,o.emit=g3.bind(null,o),e.ce&&e.ce(o),o}let Xn=null;const Aa=()=>Xn||Yn;let bS,Tl,FC="__VUE_INSTANCE_SETTERS__";(Tl=Lh()[FC])||(Tl=Lh()[FC]=[]),Tl.push(e=>Xn=e),bS=e=>{Tl.length>1?Tl.forEach(t=>t(e)):Tl[0](e)};const us=e=>{bS(e),e.scope.on()},ts=()=>{Xn&&Xn.scope.off(),bS(null)};function VN(e){return e.vnode.shapeFlag&4}let Yl=!1;function vS(e,t=!1){Yl=t;const{props:n,children:r}=e.vnode,a=VN(e);MG(e,n,a,t),FG(e,r);const o=a?XG(e,t):void 0;return Yl=!1,o}function XG(e,t){const n=e.type;e.accessCache=Object.create(null),e.proxy=XE(new Proxy(e.ctx,Gh));const{setup:r}=n;if(r){const a=e.setupContext=r.length>1?zN(e):null;us(e),nu();const o=Ya(r,e,0,[e.props,a]);if(ru(),ts(),gf(o)){if(o.then(ts,ts),t)return o.then(l=>{zh(e,l,t)}).catch(l=>{el(l,e,0)});e.asyncDep=o}else zh(e,o,t)}else TS(e,t)}function zh(e,t,n){Ft(t)?e.type.__ssrInlineRender?e.ssrRender=t:e.render=t:ln(t)&&(e.setupState=tS(t)),TS(e,n)}let Md,Kh;function ZG(e){Md=e,Kh=t=>{t.render._rc&&(t.withProxy=new Proxy(t.ctx,nG))}}const $h=()=>!Md;function TS(e,t,n){const r=e.type;if(H3(e),!e.render){if(!t&&Md&&!r.render){const a=e.vnode.props&&e.vnode.props["inline-template"]||r.template||Tc(e).template;if(a){const{isCustomElement:o,compilerOptions:l}=e.appContext.config,{delimiters:u,compilerOptions:c}=r,d=sn(sn({isCustomElement:o,delimiters:u},l),c);d.compatConfig=Object.create(rS),r.compatConfig&&sn(d.compatConfig,r.compatConfig),r.render=Md(a,d)}}e.render=r.render||vi,Kh&&Kh(e)}if(!n){us(e),nu();try{hG(e)}finally{ru(),ts()}}}function JG(e){return e.attrsProxy||(e.attrsProxy=new Proxy(e.attrs,{get(t,n){return ri(e,"get","$attrs"),t[n]}}))}function zN(e){const t=n=>{e.exposed=n||{}};return{get attrs(){return JG(e)},slots:e.slots,emit:e.emit,expose:t}}function Lf(e){if(e.exposed)return e.exposeProxy||(e.exposeProxy=new Proxy(tS(XE(e.exposed)),{get(t,n){if(n in t)return t[n];if(n in Ml)return Ml[n](e)},has(t,n){return n in t||n in Ml}}))}function Qh(e,t=!0){return Ft(e)?e.displayName||e.name:e.name||t&&e.__name}function eH(e){return Ft(e)&&"__vccOpts"in e}const KN=(e,t)=>r3(e,t,Yl);function $N(e,t,n){const r=arguments.length;return r===2?ln(t)&&!Rt(t)?Bi(t)?En(e,null,[t]):En(e,t):En(e,null,t):(r>3?n=Array.prototype.slice.call(arguments,2):r===3&&Bi(n)&&(n=[n]),En(e,t,n))}const QN=Symbol.for("v-scx"),jN=()=>Gs(QN);function tH(){}function nH(e,t,n,r){const a=n[r];if(a&&XN(a,e))return a;const o=t();return o.memo=e.slice(),n[r]=o}function XN(e,t){const n=e.memo;if(n.length!=t.length)return!1;for(let r=0;r<n.length;r++)if(os(n[r],t[r]))return!1;return Xs>0&&bi&&bi.push(e),!0}const ZN="3.3.8",rH={createComponentInstance:SS,setupComponent:vS,renderComponentRoot:pd,setCurrentRenderingInstance:ec,isVNode:Bi,normalizeVNode:Pi},iH=rH,aH=$R,oH={warnDeprecation:c3,createCompatVue:vG,isCompatEnabled:Sn,checkCompatEnabled:yf,softAssertCompatEnabled:yo},za=oH,sH="http://www.w3.org/2000/svg",Rs=typeof document<"u"?document:null,BC=Rs&&Rs.createElement("template"),lH={insert:(e,t,n)=>{t.insertBefore(e,n||null)},remove:e=>{const t=e.parentNode;t&&t.removeChild(e)},createElement:(e,t,n,r)=>{const a=t?Rs.createElementNS(sH,e):Rs.createElement(e,n?{is:n}:void 0);return e==="select"&&r&&r.multiple!=null&&a.setAttribute("multiple",r.multiple),a},createText:e=>Rs.createTextNode(e),createComment:e=>Rs.createComment(e),setText:(e,t)=>{e.nodeValue=t},setElementText:(e,t)=>{e.textContent=t},parentNode:e=>e.parentNode,nextSibling:e=>e.nextSibling,querySelector:e=>Rs.querySelector(e),setScopeId(e,t){e.setAttribute(t,"")},insertStaticContent(e,t,n,r,a,o){const l=n?n.previousSibling:t.lastChild;if(a&&(a===o||a.nextSibling))for(;t.insertBefore(a.cloneNode(!0),n),!(a===o||!(a=a.nextSibling)););else{BC.innerHTML=r?`<svg>${e}</svg>`:e;const u=BC.content;if(r){const c=u.firstChild;for(;c.firstChild;)u.appendChild(c.firstChild);u.removeChild(c)}t.insertBefore(u,n)}return[l?l.nextSibling:t.firstChild,n?n.previousSibling:t.lastChild]}},Vo="transition",Ru="animation",Wl=Symbol("_vtc"),yc=(e,{slots:t})=>$N(tN,eI(e),t);yc.displayName="Transition";yc.__isBuiltIn=!0;const JN={name:String,type:String,css:{type:Boolean,default:!0},duration:[String,Number,Object],enterFromClass:String,enterActiveClass:String,enterToClass:String,appearFromClass:String,appearActiveClass:String,appearToClass:String,leaveFromClass:String,leaveActiveClass:String,leaveToClass:String},uH=yc.props=sn({},fS,JN),Ts=(e,t=[])=>{Rt(e)?e.forEach(n=>n(...t)):e&&e(...t)},UC=e=>e?Rt(e)?e.some(t=>t.length>1):e.length>1:!1;function eI(e){const t={};for(const ne in e)ne in JN||(t[ne]=e[ne]);if(e.css===!1)return t;const{name:n="v",type:r,duration:a,enterFromClass:o=`${n}-enter-from`,enterActiveClass:l=`${n}-enter-active`,enterToClass:u=`${n}-enter-to`,appearFromClass:c=o,appearActiveClass:d=l,appearToClass:S=u,leaveFromClass:_=`${n}-leave-from`,leaveActiveClass:E=`${n}-leave-active`,leaveToClass:T=`${n}-leave-to`}=e,y=za.isCompatEnabled("TRANSITION_CLASSES",null);let M,v,A;if(y){const ne=te=>te.replace(/-from$/,"");e.enterFromClass||(M=ne(o)),e.appearFromClass||(v=ne(c)),e.leaveFromClass||(A=ne(_))}const O=cH(a),N=O&&O[0],R=O&&O[1],{onBeforeEnter:L,onEnter:I,onEnterCancelled:h,onLeave:k,onLeaveCancelled:F,onBeforeAppear:z=L,onAppear:K=I,onAppearCancelled:ue=h}=t,Z=(ne,te,G)=>{ka(ne,te?S:u),ka(ne,te?d:l),G&&G()},fe=(ne,te)=>{ne._isLeaving=!1,ka(ne,_),ka(ne,T),ka(ne,E),te&&te()},V=ne=>(te,G)=>{const se=ne?K:I,ve=()=>Z(te,ne,G);Ts(se,[te,ve]),GC(()=>{if(ka(te,ne?c:o),y){const Ge=ne?v:M;Ge&&ka(te,Ge)}na(te,ne?S:u),UC(se)||HC(te,r,N,ve)})};return sn(t,{onBeforeEnter(ne){Ts(L,[ne]),na(ne,o),y&&M&&na(ne,M),na(ne,l)},onBeforeAppear(ne){Ts(z,[ne]),na(ne,c),y&&v&&na(ne,v),na(ne,d)},onEnter:V(!1),onAppear:V(!0),onLeave(ne,te){ne._isLeaving=!0;const G=()=>fe(ne,te);na(ne,_),y&&A&&na(ne,A),nI(),na(ne,E),GC(()=>{!ne._isLeaving||(ka(ne,_),y&&A&&ka(ne,A),na(ne,T),UC(k)||HC(ne,r,R,G))}),Ts(k,[ne,G])},onEnterCancelled(ne){Z(ne,!1),Ts(h,[ne])},onAppearCancelled(ne){Z(ne,!0),Ts(ue,[ne])},onLeaveCancelled(ne){fe(ne),Ts(F,[ne])}})}function cH(e){if(e==null)return null;if(ln(e))return[sh(e.enter),sh(e.leave)];{const t=sh(e);return[t,t]}}function sh(e){return Od(e)}function na(e,t){t.split(/\s+/).forEach(n=>n&&e.classList.add(n)),(e[Wl]||(e[Wl]=new Set)).add(t)}function ka(e,t){t.split(/\s+/).forEach(r=>r&&e.classList.remove(r));const n=e[Wl];n&&(n.delete(t),n.size||(e[Wl]=void 0))}function GC(e){requestAnimationFrame(()=>{requestAnimationFrame(e)})}let dH=0;function HC(e,t,n,r){const a=e._endId=++dH,o=()=>{a===e._endId&&r()};if(n)return setTimeout(o,n);const{type:l,timeout:u,propCount:c}=tI(e,t);if(!l)return r();const d=l+"end";let S=0;const _=()=>{e.removeEventListener(d,E),o()},E=T=>{T.target===e&&++S>=c&&_()};setTimeout(()=>{S<c&&_()},u+1),e.addEventListener(d,E)}function tI(e,t){const n=window.getComputedStyle(e),r=y=>(n[y]||"").split(", "),a=r(`${Vo}Delay`),o=r(`${Vo}Duration`),l=qC(a,o),u=r(`${Ru}Delay`),c=r(`${Ru}Duration`),d=qC(u,c);let S=null,_=0,E=0;t===Vo?l>0&&(S=Vo,_=l,E=o.length):t===Ru?d>0&&(S=Ru,_=d,E=c.length):(_=Math.max(l,d),S=_>0?l>d?Vo:Ru:null,E=S?S===Vo?o.length:c.length:0);const T=S===Vo&&/\b(transform|all)(,|$)/.test(r(`${Vo}Property`).toString());return{type:S,timeout:_,propCount:E,hasTransform:T}}function qC(e,t){for(;e.length<t.length;)e=e.concat(e);return Math.max(...t.map((n,r)=>YC(n)+YC(e[r])))}function YC(e){return e==="auto"?0:Number(e.slice(0,-1).replace(",","."))*1e3}function nI(){return document.body.offsetHeight}function fH(e,t,n){const r=e[Wl];r&&(t=(t?[t,...r]:[...r]).join(" ")),t==null?e.removeAttribute("class"):n?e.setAttribute("class",t):e.className=t}const yS=Symbol("_vod"),CS={beforeMount(e,{value:t},{transition:n}){e[yS]=e.style.display==="none"?"":e.style.display,n&&t?n.beforeEnter(e):Nu(e,t)},mounted(e,{value:t},{transition:n}){n&&t&&n.enter(e)},updated(e,{value:t,oldValue:n},{transition:r}){!t!=!n&&(r?t?(r.beforeEnter(e),Nu(e,!0),r.enter(e)):r.leave(e,()=>{Nu(e,!1)}):Nu(e,t))},beforeUnmount(e,{value:t}){Nu(e,t)}};function Nu(e,t){e.style.display=t?e[yS]:"none"}function pH(){CS.getSSRProps=({value:e})=>{if(!e)return{style:{display:"none"}}}}function _H(e,t,n){const r=e.style,a=xn(n);if(n&&!a){if(t&&!xn(t))for(const o in t)n[o]==null&&jh(r,o,"");for(const o in n)jh(r,o,n[o])}else{const o=r.display;a?t!==n&&(r.cssText=n):t&&e.removeAttribute("style"),yS in e&&(r.display=o)}}const WC=/\s*!important$/;function jh(e,t,n){if(Rt(n))n.forEach(r=>jh(e,t,r));else if(n==null&&(n=""),t.startsWith("--"))e.setProperty(t,n);else{const r=mH(e,t);WC.test(n)?e.setProperty(ei(r),n.replace(WC,""),"important"):e[r]=n}}const VC=["Webkit","Moz","ms"],lh={};function mH(e,t){const n=lh[t];if(n)return n;let r=ni(t);if(r!=="filter"&&r in e)return lh[t]=r;r=gc(r);for(let a=0;a<VC.length;a++){const o=VC[a]+r;if(o in e)return lh[t]=o}return t}const zC="http://www.w3.org/1999/xlink";function gH(e,t,n,r,a){if(r&&t.startsWith("xlink:"))n==null?e.removeAttributeNS(zC,t.slice(6,t.length)):e.setAttributeNS(zC,t,n);else{if(EH(e,t,n,a))return;const o=SR(t);n==null||o&&!bR(n)?e.removeAttribute(t):e.setAttribute(t,o?"":n)}}const hH=Jl("contenteditable,draggable,spellcheck");function EH(e,t,n,r=null){if(hH(t)){const a=n===null?"false":typeof n!="boolean"&&n!==void 0?"true":null;if(a&&za.softAssertCompatEnabled("ATTR_ENUMERATED_COERCION",r,t,n,a))return e.setAttribute(t,a),!0}else if(n===!1&&!SR(t)&&za.softAssertCompatEnabled("ATTR_FALSE_VALUE",r,t))return e.removeAttribute(t),!0;return!1}function SH(e,t,n,r,a,o,l){if(t==="innerHTML"||t==="textContent"){r&&l(r,a,o),e[t]=n==null?"":n;return}const u=e.tagName;if(t==="value"&&u!=="PROGRESS"&&!u.includes("-")){e._value=n;const d=u==="OPTION"?e.getAttribute("value"):e.value,S=n==null?"":n;d!==S&&(e.value=S),n==null&&e.removeAttribute(t);return}let c=!1;if(n===""||n==null){const d=typeof e[t];d==="boolean"?n=bR(n):n==null&&d==="string"?(n="",c=!0):d==="number"&&(n=0,c=!0)}else if(n===!1&&za.isCompatEnabled("ATTR_FALSE_VALUE",a)){const d=typeof e[t];(d==="string"||d==="number")&&(n=d==="number"?0:"",c=!0)}try{e[t]=n}catch{}c&&e.removeAttribute(t)}function Eo(e,t,n,r){e.addEventListener(t,n,r)}function bH(e,t,n,r){e.removeEventListener(t,n,r)}const KC=Symbol("_vei");function vH(e,t,n,r,a=null){const o=e[KC]||(e[KC]={}),l=o[t];if(r&&l)l.value=r;else{const[u,c]=TH(t);if(r){const d=o[t]=AH(r,a);Eo(e,u,d,c)}else l&&(bH(e,u,l,c),o[t]=void 0)}}const $C=/(?:Once|Passive|Capture)$/;function TH(e){let t;if($C.test(e)){t={};let r;for(;r=e.match($C);)e=e.slice(0,e.length-r[0].length),t[r[0].toLowerCase()]=!0}return[e[2]===":"?e.slice(3):ei(e.slice(2)),t]}let uh=0;const yH=Promise.resolve(),CH=()=>uh||(yH.then(()=>uh=0),uh=Date.now());function AH(e,t){const n=r=>{if(!r._vts)r._vts=Date.now();else if(r._vts<=n.attached)return;Ti(OH(r,n.value),t,5,[r])};return n.value=e,n.attached=CH(),n}function OH(e,t){if(Rt(t)){const n=e.stopImmediatePropagation;return e.stopImmediatePropagation=()=>{n.call(e),e._stopped=!0},t.map(r=>a=>!a._stopped&&r&&r(a))}else return t}const QC=/^on[a-z]/,RH=(e,t,n,r,a=!1,o,l,u,c)=>{t==="class"?fH(e,r,a):t==="style"?_H(e,n,r):Co(t)?YE(t)||vH(e,t,n,r,l):(t[0]==="."?(t=t.slice(1),!0):t[0]==="^"?(t=t.slice(1),!1):NH(e,t,r,a))?SH(e,t,r,o,l,u,c):(t==="true-value"?e._trueValue=r:t==="false-value"&&(e._falseValue=r),gH(e,t,r,a,l))};function NH(e,t,n,r){return r?!!(t==="innerHTML"||t==="textContent"||t in e&&QC.test(t)&&Ft(n)):t==="spellcheck"||t==="draggable"||t==="translate"||t==="form"||t==="list"&&e.tagName==="INPUT"||t==="type"&&e.tagName==="TEXTAREA"||QC.test(t)&&xn(n)?!1:t in e}/*! #__NO_SIDE_EFFECTS__ */function rI(e,t){const n=pS(e);class r extends Mf{constructor(o){super(n,o,t)}}return r.def=n,r}/*! #__NO_SIDE_EFFECTS__ */const IH=e=>rI(e,pI),DH=typeof HTMLElement<"u"?HTMLElement:class{};class Mf extends DH{constructor(t,n={},r){super(),this._def=t,this._props=n,this._instance=null,this._connected=!1,this._resolved=!1,this._numberProps=null,this._ob=null,this.shadowRoot&&r?r(this._createVNode(),this.shadowRoot):(this.attachShadow({mode:"open"}),this._def.__asyncLoader||this._resolveProps(this._def))}connectedCallback(){this._connected=!0,this._instance||(this._resolved?this._update():this._resolveDef())}disconnectedCallback(){this._connected=!1,this._ob&&(this._ob.disconnect(),this._ob=null),Ec(()=>{this._connected||(Jh(null,this.shadowRoot),this._instance=null)})}_resolveDef(){this._resolved=!0;for(let r=0;r<this.attributes.length;r++)this._setAttr(this.attributes[r].name);this._ob=new MutationObserver(r=>{for(const a of r)this._setAttr(a.attributeName)}),this._ob.observe(this,{attributes:!0});const t=(r,a=!1)=>{const{props:o,styles:l}=r;let u;if(o&&!Rt(o))for(const c in o){const d=o[c];(d===Number||d&&d.type===Number)&&(c in this._props&&(this._props[c]=Od(this._props[c])),(u||(u=Object.create(null)))[ni(c)]=!0)}this._numberProps=u,a&&this._resolveProps(r),this._applyStyles(l),this._update()},n=this._def.__asyncLoader;n?n().then(r=>t(r,!0)):t(this._def)}_resolveProps(t){const{props:n}=t,r=Rt(n)?n:Object.keys(n||{});for(const a of Object.keys(this))a[0]!=="_"&&r.includes(a)&&this._setProp(a,this[a],!0,!1);for(const a of r.map(ni))Object.defineProperty(this,a,{get(){return this._getProp(a)},set(o){this._setProp(a,o)}})}_setAttr(t){let n=this.getAttribute(t);const r=ni(t);this._numberProps&&this._numberProps[r]&&(n=Od(n)),this._setProp(r,n,!1)}_getProp(t){return this._props[t]}_setProp(t,n,r=!0,a=!0){n!==this._props[t]&&(this._props[t]=n,a&&this._instance&&this._update(),r&&(n===!0?this.setAttribute(ei(t),""):typeof n=="string"||typeof n=="number"?this.setAttribute(ei(t),n+""):n||this.removeAttribute(ei(t))))}_update(){Jh(this._createVNode(),this.shadowRoot)}_createVNode(){const t=En(this._def,sn({},this._props));return this._instance||(t.ce=n=>{this._instance=n,n.isCE=!0;const r=(o,l)=>{this.dispatchEvent(new CustomEvent(o,{detail:l}))};n.emit=(o,...l)=>{r(o,l),ei(o)!==o&&r(ei(o),l)};let a=this;for(;a=a&&(a.parentNode||a.host);)if(a instanceof Mf){n.parent=a._instance,n.provides=a._instance.provides;break}}),t}_applyStyles(t){t&&t.forEach(n=>{const r=document.createElement("style");r.textContent=n,this.shadowRoot.appendChild(r)})}}function xH(e="$style"){{const t=Aa();if(!t)return yn;const n=t.type.__cssModules;if(!n)return yn;const r=n[e];return r||yn}}function wH(e){const t=Aa();if(!t)return;const n=t.ut=(a=e(t.proxy))=>{Array.from(document.querySelectorAll(`[data-v-owner="${t.uid}"]`)).forEach(o=>Zh(o,a))},r=()=>{const a=e(t.proxy);Xh(t.subTree,a),n(a)};XR(r),vc(()=>{const a=new MutationObserver(r);a.observe(t.subTree.el.parentNode,{childList:!0}),rc(()=>a.disconnect())})}function Xh(e,t){if(e.shapeFlag&128){const n=e.suspense;e=n.activeBranch,n.pendingBranch&&!n.isHydrating&&n.effects.push(()=>{Xh(n.activeBranch,t)})}for(;e.component;)e=e.component.subTree;if(e.shapeFlag&1&&e.el)Zh(e.el,t);else if(e.type===hr)e.children.forEach(n=>Xh(n,t));else if(e.type===Hs){let{el:n,anchor:r}=e;for(;n&&(Zh(n,t),n!==r);)n=n.nextSibling}}function Zh(e,t){if(e.nodeType===1){const n=e.style;for(const r in t)n.setProperty(`--${r}`,t[r])}}const iI=new WeakMap,aI=new WeakMap,kd=Symbol("_moveCb"),jC=Symbol("_enterCb"),AS={name:"TransitionGroup",props:sn({},uH,{tag:String,moveClass:String}),setup(e,{slots:t}){const n=Aa(),r=dS();let a,o;return If(()=>{if(!a.length)return;const l=e.moveClass||`${e.name||"v"}-move`;if(!FH(a[0].el,n.vnode.el,l))return;a.forEach(MH),a.forEach(kH);const u=a.filter(PH);nI(),u.forEach(c=>{const d=c.el,S=d.style;na(d,l),S.transform=S.webkitTransform=S.transitionDuration="";const _=d[kd]=E=>{E&&E.target!==d||(!E||/transform$/.test(E.propertyName))&&(d.removeEventListener("transitionend",_),d[kd]=null,ka(d,l))};d.addEventListener("transitionend",_)})}),()=>{const l=pn(e),u=eI(l);let c=l.tag||hr;!l.tag&&za.checkCompatEnabled("TRANSITION_GROUP_ROOT",n.parent)&&(c="span"),a=o,o=t.default?Rf(t.default()):[];for(let d=0;d<o.length;d++){const S=o[d];S.key!=null&&Qs(S,Hl(S,u,r,n))}if(a)for(let d=0;d<a.length;d++){const S=a[d];Qs(S,Hl(S,u,r,n)),iI.set(S,S.el.getBoundingClientRect())}return En(c,null,o)}}};AS.__isBuiltIn=!0;const LH=e=>delete e.mode;AS.props;const oI=AS;function MH(e){const t=e.el;t[kd]&&t[kd](),t[jC]&&t[jC]()}function kH(e){aI.set(e,e.el.getBoundingClientRect())}function PH(e){const t=iI.get(e),n=aI.get(e),r=t.left-n.left,a=t.top-n.top;if(r||a){const o=e.el.style;return o.transform=o.webkitTransform=`translate(${r}px,${a}px)`,o.transitionDuration="0s",e}}function FH(e,t,n){const r=e.cloneNode(),a=e[Wl];a&&a.forEach(u=>{u.split(/\s+/).forEach(c=>c&&r.classList.remove(c))}),n.split(/\s+/).forEach(u=>u&&r.classList.add(u)),r.style.display="none";const o=t.nodeType===1?t:t.parentNode;o.appendChild(r);const{hasTransform:l}=tI(r);return o.removeChild(r),l}const cs=e=>{const t=e.props["onUpdate:modelValue"]||e.props["onModelCompat:input"];return Rt(t)?n=>Jo(t,n):t};function BH(e){e.target.composing=!0}function XC(e){const t=e.target;t.composing&&(t.composing=!1,t.dispatchEvent(new Event("input")))}const ra=Symbol("_assign"),Pd={created(e,{modifiers:{lazy:t,trim:n,number:r}},a){e[ra]=cs(a);const o=r||a.props&&a.props.type==="number";Eo(e,t?"change":"input",l=>{if(l.target.composing)return;let u=e.value;n&&(u=u.trim()),o&&(u=Qu(u)),e[ra](u)}),n&&Eo(e,"change",()=>{e.value=e.value.trim()}),t||(Eo(e,"compositionstart",BH),Eo(e,"compositionend",XC),Eo(e,"change",XC))},mounted(e,{value:t}){e.value=t==null?"":t},beforeUpdate(e,{value:t,modifiers:{lazy:n,trim:r,number:a}},o){if(e[ra]=cs(o),e.composing||document.activeElement===e&&e.type!=="range"&&(n||r&&e.value.trim()===t||(a||e.type==="number")&&Qu(e.value)===t))return;const l=t==null?"":t;e.value!==l&&(e.value=l)}},OS={deep:!0,created(e,t,n){e[ra]=cs(n),Eo(e,"change",()=>{const r=e._modelValue,a=Vl(e),o=e.checked,l=e[ra];if(Rt(r)){const u=hc(r,a),c=u!==-1;if(o&&!c)l(r.concat(a));else if(!o&&c){const d=[...r];d.splice(u,1),l(d)}}else if(Js(r)){const u=new Set(r);o?u.add(a):u.delete(a),l(u)}else l(lI(e,o))})},mounted:ZC,beforeUpdate(e,t,n){e[ra]=cs(n),ZC(e,t,n)}};function ZC(e,{value:t,oldValue:n},r){e._modelValue=t,Rt(t)?e.checked=hc(t,r.props.value)>-1:Js(t)?e.checked=t.has(r.props.value):t!==n&&(e.checked=To(t,lI(e,!0)))}const RS={created(e,{value:t},n){e.checked=To(t,n.props.value),e[ra]=cs(n),Eo(e,"change",()=>{e[ra](Vl(e))})},beforeUpdate(e,{value:t,oldValue:n},r){e[ra]=cs(r),t!==n&&(e.checked=To(t,r.props.value))}},sI={deep:!0,created(e,{value:t,modifiers:{number:n}},r){const a=Js(t);Eo(e,"change",()=>{const o=Array.prototype.filter.call(e.options,l=>l.selected).map(l=>n?Qu(Vl(l)):Vl(l));e[ra](e.multiple?a?new Set(o):o:o[0])}),e[ra]=cs(r)},mounted(e,{value:t}){JC(e,t)},beforeUpdate(e,t,n){e[ra]=cs(n)},updated(e,{value:t}){JC(e,t)}};function JC(e,t){const n=e.multiple;if(!(n&&!Rt(t)&&!Js(t))){for(let r=0,a=e.options.length;r<a;r++){const o=e.options[r],l=Vl(o);if(n)Rt(t)?o.selected=hc(t,l)>-1:o.selected=t.has(l);else if(To(Vl(o),t)){e.selectedIndex!==r&&(e.selectedIndex=r);return}}!n&&e.selectedIndex!==-1&&(e.selectedIndex=-1)}}function Vl(e){return"_value"in e?e._value:e.value}function lI(e,t){const n=t?"_trueValue":"_falseValue";return n in e?e[n]:t}const NS={created(e,t,n){ud(e,t,n,null,"created")},mounted(e,t,n){ud(e,t,n,null,"mounted")},beforeUpdate(e,t,n,r){ud(e,t,n,r,"beforeUpdate")},updated(e,t,n,r){ud(e,t,n,r,"updated")}};function uI(e,t){switch(e){case"SELECT":return sI;case"TEXTAREA":return Pd;default:switch(t){case"checkbox":return OS;case"radio":return RS;default:return Pd}}}function ud(e,t,n,r,a){const l=uI(e.tagName,n.props&&n.props.type)[a];l&&l(e,t,n,r)}function UH(){Pd.getSSRProps=({value:e})=>({value:e}),RS.getSSRProps=({value:e},t)=>{if(t.props&&To(t.props.value,e))return{checked:!0}},OS.getSSRProps=({value:e},t)=>{if(Rt(e)){if(t.props&&hc(e,t.props.value)>-1)return{checked:!0}}else if(Js(e)){if(t.props&&e.has(t.props.value))return{checked:!0}}else if(e)return{checked:!0}},NS.getSSRProps=(e,t)=>{if(typeof t.type!="string")return;const n=uI(t.type.toUpperCase(),t.props&&t.props.type);if(n.getSSRProps)return n.getSSRProps(e,t)}}const GH=["ctrl","shift","alt","meta"],HH={stop:e=>e.stopPropagation(),prevent:e=>e.preventDefault(),self:e=>e.target!==e.currentTarget,ctrl:e=>!e.ctrlKey,shift:e=>!e.shiftKey,alt:e=>!e.altKey,meta:e=>!e.metaKey,left:e=>"button"in e&&e.button!==0,middle:e=>"button"in e&&e.button!==1,right:e=>"button"in e&&e.button!==2,exact:(e,t)=>GH.some(n=>e[`${n}Key`]&&!t.includes(n))},qH=(e,t)=>(n,...r)=>{for(let a=0;a<t.length;a++){const o=HH[t[a]];if(o&&o(n,t))return}return e(n,...r)},YH={esc:"escape",space:" ",up:"arrow-up",left:"arrow-left",right:"arrow-right",down:"arrow-down",delete:"backspace"},WH=(e,t)=>{let n,r=null;return r=Aa(),za.isCompatEnabled("CONFIG_KEY_CODES",r)&&r&&(n=r.appContext.config.keyCodes),a=>{if(!("key"in a))return;const o=ei(a.key);if(t.some(l=>l===o||YH[l]===o))return e(a);{const l=String(a.keyCode);if(za.isCompatEnabled("V_ON_KEYCODE_MODIFIER",r)&&t.some(u=>u==l))return e(a);if(n)for(const u of t){const c=n[u];if(c&&(Rt(c)?c.some(S=>String(S)===l):String(c)===l))return e(a)}}}},cI=sn({patchProp:RH},lH);let Bu,eA=!1;function dI(){return Bu||(Bu=PN(cI))}function fI(){return Bu=eA?Bu:FN(cI),eA=!0,Bu}const Jh=(...e)=>{dI().render(...e)},pI=(...e)=>{fI().hydrate(...e)},IS=(...e)=>{const t=dI().createApp(...e),{mount:n}=t;return t.mount=r=>{const a=_I(r);if(!a)return;const o=t._component;!Ft(o)&&!o.render&&!o.template&&(o.template=a.innerHTML),a.innerHTML="";const l=n(a,!1,a instanceof SVGElement);return a instanceof Element&&(a.removeAttribute("v-cloak"),a.setAttribute("data-v-app","")),l},t},VH=(...e)=>{const t=fI().createApp(...e),{mount:n}=t;return t.mount=r=>{const a=_I(r);if(a)return n(a,!0,a instanceof SVGElement)},t};function _I(e){return xn(e)?document.querySelector(e):e}let tA=!1;const zH=()=>{tA||(tA=!0,UH(),pH())};var KH=Object.freeze({__proto__:null,BaseTransition:tN,BaseTransitionPropsValidators:fS,Comment:Dr,EffectScope:zE,Fragment:hr,KeepAlive:iN,ReactiveEffect:Gl,Static:Hs,Suspense:N3,Teleport:WG,Text:js,Transition:yc,TransitionGroup:oI,VueElement:Mf,assertNumber:a3,callWithAsyncErrorHandling:Ti,callWithErrorHandling:Ya,camelize:ni,capitalize:gc,cloneVNode:va,compatUtils:za,computed:KN,createApp:IS,createBlock:hS,createCommentVNode:Ld,createElementBlock:Ma,createElementVNode:on,createHydrationRenderer:FN,createPropsRestProxy:mG,createRenderer:PN,createSSRApp:VH,createSlots:EN,createStaticVNode:ES,createTextVNode:ql,createVNode:En,customRef:XU,defineAsyncComponent:_d,defineComponent:pS,defineCustomElement:rI,defineEmits:iG,defineExpose:aG,defineModel:lG,defineOptions:oG,defineProps:rG,defineSSRCustomElement:IH,defineSlots:sG,get devtools(){return yl},effect:yU,effectScope:SU,getCurrentInstance:Aa,getCurrentScope:yR,getTransitionRawChildren:Rf,guardReactiveProps:WN,h:$N,handleError:el,hasInjectionContext:wG,hydrate:pI,initCustomFormatter:tH,initDirectivesForSSR:zH,inject:Gs,isMemoSame:XN,isProxy:jE,isReactive:So,isReadonly:$s,isRef:sr,isRuntimeOnly:$h,isShallow:ju,isVNode:Bi,markRaw:XE,mergeDefaults:pG,mergeModels:_G,mergeProps:wf,nextTick:Ec,normalizeClass:Va,normalizeProps:gU,normalizeStyle:tu,onActivated:aN,onBeforeMount:lN,onBeforeUnmount:nc,onBeforeUpdate:uN,onDeactivated:oN,onErrorCaptured:pN,onMounted:vc,onRenderTracked:fN,onRenderTriggered:dN,onScopeDispose:bU,onServerPrefetch:cN,onUnmounted:rc,onUpdated:If,openBlock:ki,popScopeId:E3,provide:IN,proxyRefs:tS,pushScopeId:h3,queuePostFlushCb:Id,reactive:ls,readonly:QE,ref:Dl,registerRuntimeCompiler:ZG,render:Jh,renderList:_S,renderSlot:SN,resolveComponent:O3,resolveDirective:KR,resolveDynamicComponent:zR,resolveFilter:aH,resolveTransitionHooks:Hl,setBlockTracking:Vh,setDevtoolsHook:qR,setTransitionHooks:Qs,shallowReactive:PR,shallowReadonly:WU,shallowRef:VU,ssrContextKey:QN,ssrUtils:iH,stop:CU,toDisplayString:Rd,toHandlerKey:Il,toHandlers:vN,toRaw:pn,toRef:t3,toRefs:ZU,toValue:$U,transformVNodeArgs:KG,triggerRef:KU,unref:eS,useAttrs:dG,useCssModule:xH,useCssVars:wH,useModel:fG,useSSRContext:jN,useSlots:cG,useTransitionState:dS,vModelCheckbox:OS,vModelDynamic:NS,vModelRadio:RS,vModelSelect:sI,vModelText:Pd,vShow:CS,version:ZN,warn:i3,watch:Ps,watchEffect:P3,watchPostEffect:XR,watchSyncEffect:F3,withAsyncContext:gG,withCtx:sS,withDefaults:uG,withDirectives:JR,withKeys:WH,withMemo:nH,withModifiers:qH,withScopeId:S3});function $H(...e){const t=IS(...e);return za.isCompatEnabled("RENDER_FUNCTION",null)&&(t.component("__compat__transition",yc),t.component("__compat__transition-group",oI),t.component("__compat__keep-alive",iN),t._context.directives.show=CS,t._context.directives.model=NS),t}function QH(){const e=za.createCompatVue(IS,$H);return sn(e,KH),e}const mI=QH();mI.compile=()=>{};var jH=mI;function XH(e){let t=0;for(let o=0;o<e.length;o++)t=e.charCodeAt(o)+((t<<5)-t),t=t&t;let n=(t%360+360)%360,r=(t%25+25)%25+75,a=(t%20+20)%20+40;return`hsl(${n}, ${r}%, ${a}%)`}function ZH(e,t){At(t).select(),document.execCommand("copy"),At(e.target).tooltip({title:"Copi\xE9!",trigger:"manual"}),At(e.target).tooltip("show"),setTimeout(function(){At(e.target).tooltip("hide")},1500)}const JH={htmlEntities:zA,colorHash:XH,copyToClipboard:ZH},eq={upload:(e,t,n)=>{const r=window.CTFd;try{e instanceof At&&(form=form[0]);var e=new FormData(e);e.append("nonce",r.config.csrfNonce);for(let[l,u]of Object.entries(t))e.append(l,u)}catch{e.append("nonce",r.config.csrfNonce);for(let[l,u]of Object.entries(t))e.append(l,u)}var a=wu.ezProgressBar({width:0,title:"Progr\xE8s de l'envoi"});At.ajax({url:r.config.urlRoot+"/api/v1/files?admin=true",data:e,type:"POST",cache:!1,contentType:!1,processData:!1,xhr:function(){var o=At.ajaxSettings.xhr();return o.upload.onprogress=function(l){if(l.lengthComputable){var u=l.loaded/l.total*100;a=wu.ezProgressBar({target:a,width:u})}},o},success:function(o){a=wu.ezProgressBar({target:a,width:100}),setTimeout(function(){a.modal("hide")},500),n&&n(o)}})}},tq={get_comments:e=>window.CTFd.fetch("/api/v1/comments?"+At.param(e),{method:"GET",credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"}}).then(function(n){return n.json()}),add_comment:(e,t,n,r)=>{const a=window.CTFd;let o={content:e,type:t,...n};a.fetch("/api/v1/comments",{method:"POST",credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"},body:JSON.stringify(o)}).then(function(l){return l.json()}).then(function(l){r&&r(l)})},delete_comment:e=>window.CTFd.fetch(`/api/v1/comments/${e}`,{method:"DELETE",credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"}}).then(function(n){return n.json()})},gI={files:eq,comments:tq,utils:JH,ezq:wu},nq=(e,t)=>{const n=e.__vccOpts||e;for(const[r,a]of t)n[r]=a;return n};function rq(){return Ys.fetch("/api/v1/files?type=page",{credentials:"same-origin"}).then(function(e){return e.json()})}const iq={props:{editor:Object},data:function(){return{files:[],selectedFile:null}},methods:{getPageFiles:function(){rq().then(e=>(this.files=e.data,this.files))},uploadChosenFiles:function(){let e=document.querySelector("#media-library-upload");gI.files.upload(e,{},t=>{this.getPageFiles()})},selectFile:function(e){return this.selectedFile=e,this.selectedFile},buildSelectedFileUrl:function(){return Ys.config.urlRoot+"/files/"+this.selectedFile.location},deleteSelectedFile:function(){var e=this.selectedFile.id;confirm("\xCAtes-vous certain de vouloir supprimer this file?")&&Ys.fetch("/api/v1/files/"+e,{method:"DELETE"}).then(t=>{t.status===200&&t.json().then(n=>{n.success&&(this.getPageFiles(),this.selectedFile=null)})})},insertSelectedFile:function(){let e=this.$props.editor;e.hasOwnProperty("codemirror")&&(e=e.codemirror);let t=e.getDoc(),n=t.getCursor(),r=this.buildSelectedFileUrl(),a=this.getIconClass(this.selectedFile.location)==="far fa-file-image",o=r.split("/").pop();link="[{0}]({1})".format(o,r),a&&(link="!"+link),t.replaceRange(link,n)},downloadSelectedFile:function(){var e=this.buildSelectedFileUrl();window.open(e,"_blank")},getIconClass:function(e){var t={png:"far fa-file-image",jpg:"far fa-file-image",jpeg:"far fa-file-image",gif:"far fa-file-image",bmp:"far fa-file-image",svg:"far fa-file-image",txt:"far fa-file-alt",mov:"far fa-file-video",mp4:"far fa-file-video",wmv:"far fa-file-video",flv:"far fa-file-video",mkv:"far fa-file-video",avi:"far fa-file-video",pdf:"far fa-file-pdf",mp3:"far fa-file-sound",wav:"far fa-file-sound",aac:"far fa-file-sound",zip:"far fa-file-archive",gz:"far fa-file-archive",tar:"far fa-file-archive","7z":"far fa-file-archive",rar:"far fa-file-archive",py:"far fa-file-code",c:"far fa-file-code",cpp:"far fa-file-code",html:"far fa-file-code",js:"far fa-file-code",rb:"far fa-file-code",go:"far fa-file-code"},n=e.split(".").pop();return t[n]||"far fa-file"}},created(){return this.getPageFiles()}},aq={id:"media-modal",class:"modal fade",tabindex:"-1"},oq={class:"modal-dialog modal-xl"},sq={class:"modal-content"},lq=ES('<div class="modal-header"><div class="container"><div class="row"><div class="col-md-12"><h3 class="text-center">Media Library</h3></div></div></div><button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">\xD7</span></button></div>',1),uq={class:"modal-body"},cq={class:"modal-header"},dq={class:"container"},fq={class:"row mh-100"},pq={class:"col-md-6",id:"media-library-list"},_q=["onClick"],mq={class:"media-item-title pl-1"},gq={class:"col-md-6",id:"media-library-details"},hq=on("h4",{class:"text-center"},"Media Details",-1),Eq={id:"media-item"},Sq={class:"text-center",id:"media-icon"},bq={key:0},vq={key:0},Tq=["src"],yq={key:1},Cq=on("br",null,null,-1),Aq={key:0,class:"text-center",id:"media-filename"},Oq=["href"],Rq=on("br",null,null,-1),Nq={class:"form-group"},Iq={key:0},Dq=["value"],xq={key:1},wq=on("input",{class:"form-control",type:"text",id:"media-link",readonly:""},null,-1),Lq={class:"form-group text-center"},Mq={class:"row"},kq={class:"col-md-6"},Pq={class:"col-md-3"},Fq=on("i",{class:"fas fa-download"},null,-1),Bq=[Fq],Uq={class:"col-md-3"},Gq=on("i",{class:"far fa-trash-alt"},null,-1),Hq=[Gq],qq=ES('<form id="media-library-upload" enctype="multipart/form-data"><div class="form-row pt-3"><div class="col"><div class="form-group"><label for="media-files">Upload Files</label><input type="file" name="file" id="media-files" class="form-control-file" multiple><sub class="help-block"> Attach multiple files using CTRL+Click or Cmd+Click. </sub></div></div><div class="col"><div class="form-group"><label>Upload File Location</label><input class="form-control" type="text" name="location" placeholder="Location"><sub class="help-block"> Route where file will be accessible (if not provided a random folder will be used). <br> Provide as <code>directory/filename.ext</code></sub></div></div></div><input type="hidden" value="page" name="type"></form>',1),Yq={class:"modal-footer"},Wq={class:"float-right"};function Vq(e,t,n,r,a,o){return ki(),Ma("div",aq,[on("div",oq,[on("div",sq,[lq,on("div",uq,[on("div",cq,[on("div",dq,[on("div",fq,[on("div",pq,[(ki(!0),Ma(hr,null,_S(e.files,l=>(ki(),Ma("div",{class:"media-item-wrapper",key:l.id},[on("a",{href:"javascript:void(0)",onClick:u=>{o.selectFile(l)}},[on("i",{class:Va(o.getIconClass(l.location)),"aria-hidden":"true"},null,2),on("small",mq,Rd(l.location.split("/").pop()),1)],8,_q)]))),128))]),on("div",gq,[hq,on("div",Eq,[on("div",Sq,[this.selectedFile?(ki(),Ma("div",bq,[o.getIconClass(this.selectedFile.location)==="far fa-file-image"?(ki(),Ma("div",vq,[on("img",{src:o.buildSelectedFileUrl(),style:{"max-width":"100%","max-height":"100%","object-fit":"contain"}},null,8,Tq)])):(ki(),Ma("div",yq,[on("i",{class:Va(`${o.getIconClass(this.selectedFile.location)} fa-4x`),"aria-hidden":"true"},null,2)]))])):Ld("",!0)]),Cq,this.selectedFile?(ki(),Ma("div",Aq,[on("a",{href:o.buildSelectedFileUrl(),target:"_blank"},Rd(this.selectedFile.location.split("/").pop()),9,Oq)])):Ld("",!0),Rq,on("div",Nq,[this.selectedFile?(ki(),Ma("div",Iq,[ql(" Link: "),on("input",{class:"form-control",type:"text",id:"media-link",value:o.buildSelectedFileUrl(),readonly:""},null,8,Dq)])):(ki(),Ma("div",xq,[ql(" Link: "),wq]))]),on("div",Lq,[on("div",Mq,[on("div",kq,[on("button",{onClick:t[0]||(t[0]=(...l)=>o.insertSelectedFile&&o.insertSelectedFile(...l)),class:"btn btn-success w-100",id:"media-insert","data-toggle":"tooltip","data-placement":"top",title:"Insert link into editor"}," Insert ")]),on("div",Pq,[on("button",{onClick:t[1]||(t[1]=(...l)=>o.downloadSelectedFile&&o.downloadSelectedFile(...l)),class:"btn btn-primary w-100",id:"media-download","data-toggle":"tooltip","data-placement":"top",title:"Download file"},Bq)]),on("div",Uq,[on("button",{onClick:t[2]||(t[2]=(...l)=>o.deleteSelectedFile&&o.deleteSelectedFile(...l)),class:"btn btn-danger w-100",id:"media-delete","data-toggle":"tooltip","data-placement":"top",title:"Delete file"},Hq)])])])])])])])]),qq]),on("div",Yq,[on("div",Wq,[on("button",{onClick:t[3]||(t[3]=(...l)=>o.uploadChosenFiles&&o.uploadChosenFiles(...l)),type:"submit",class:"btn btn-primary media-upload-button"}," Upload ")])])])])])}const zq=nq(iq,[["render",Vq]]);function Kq(e){const t=jH.extend(zq);let n=document.createElement("div");document.querySelector("main").appendChild(n);let r=new t({propsData:{editor:e}}).$mount(n);At("#media-modal").on("hidden.bs.modal",function(a){r.$destroy(),At("#media-modal").remove()}),At("#media-modal").modal()}function $q(e){if(Object.hasOwn(e,"mde")===!1){let t=new nU({autoDownloadFontAwesome:!1,toolbar:["bold","italic","heading","|","quote","unordered-list","ordered-list","|","link","image",{name:"media",action:n=>{Kq(n)},className:"fas fa-file-upload",title:"Media Library"},"|","preview","guide"],element:e,initialValue:At(e).val(),forceSync:!0,minHeight:"200px",renderingConfig:{codeSyntaxHighlighting:!0,hljs:qd}});e.mde=t,e.codemirror=t.codemirror,At(e).on("change keyup paste",function(){t.codemirror.getDoc().setValue(At(e).val()),t.codemirror.refresh()})}}function Qq(){At("textarea.markdown").each(function(e,t){$q(t)})}function jq(){At("th.sort-col").append(' <i class="fas fa-sort"></i>'),At("th.sort-col").click(function(){var n=At(this).parents("table").eq(0),r=n.find("tr:gt(0)").toArray().sort(e(At(this).index()));this.asc=!this.asc,this.asc||(r=r.reverse());for(var a=0;a<r.length;a++)n.append(r[a])});function e(n){return function(r,a){var o=t(r,n),l=t(a,n);return At.isNumeric(o)&&At.isNumeric(l)?o-l:o.toString().localeCompare(l)}}function t(n,r){return At(n).children("td").eq(r).text()}}const Xq=()=>{At(":input").each(function(){At(this).data("initial",At(this).val())}),At(function(){At("tr[data-href], td[data-href]").click(function(){var t=getSelection().toString();if(!t){var n=At(this).attr("data-href");n&&(window.location=n)}return!1}),At("[data-checkbox]").click(function(t){if(At(t.target).is("input[type=checkbox]")){t.stopImmediatePropagation();return}At(this).find("input[type=checkbox]").click(),t.stopImmediatePropagation()}),At("[data-checkbox-all]").on("click change",function(t){const n=At(this).prop("checked"),r=At(this).index()+1;At(this).closest("table").find(`tr td:nth-child(${r}) input[type=checkbox]`).prop("checked",n),t.stopImmediatePropagation()}),At("tr[data-href] a, tr[data-href] button").click(function(t){At(this).attr("data-dismiss")||t.stopPropagation()}),At(".page-select").change(function(){let t=new URL(window.location);t.searchParams.set("page",this.value),window.location.href=t.toString()}),At('a[data-toggle="tab"]').on("shown.bs.tab",function(t){sessionStorage.setItem("activeTab",At(t.target).attr("href"))});let e=sessionStorage.getItem("activeTab");if(e){let t=At(`.nav-tabs a[href="${e}"], .nav-pills a[href="${e}"]`);t.length?t.tab("show"):sessionStorage.removeItem("activeTab")}Qq(),jq(),At('[data-toggle="tooltip"]').tooltip(),document.querySelectorAll("pre code").forEach(t=>{qd.highlightBlock(t)})})};oc.extend(oR);Ys.init(window.init);window.CTFd=Ys;window.Alpine=AB;window.helpers=gI;window.$=At;window.dayjs=oc;window.nunjucks=OB;window.Howl=PE.Howl;At(()=>{Xq(),DB(),IB(Ys.config.urlRoot)});export{At as $,Qq as A,ph as B,Ys as C,VA as D,zl as E,hr as F,wA as G,Jr as H,oc as I,qd as J,oR as K,lF as L,Kq as M,XH as N,ID as O,uF as P,ZH as Q,oI as T,jH as V,nq as _,on as a,Ld as b,Ma as c,ES as d,O3 as e,En as f,sS as g,JR as h,OS as i,ql as j,E3 as k,Pd as l,WH as m,OB as n,ki as o,h3 as p,Va as q,_S as r,gI as s,Rd as t,sF as u,sI as v,qH as w,CS as x,$q as y,zA as z}; +Maximum file size is #image_max_size#.`,importError:"Something went wrong when uploading the image #image_name#."};function It(e){e=e||{},e.parent=this;var t=!0;if(e.autoDownloadFontAwesome===!1&&(t=!1),e.autoDownloadFontAwesome!==!0)for(var n=document.styleSheets,r=0;r<n.length;r++)!n[r].href||n[r].href.indexOf("//maxcdn.bootstrapcdn.com/font-awesome/")>-1&&(t=!1);if(t){var a=document.createElement("link");a.rel="stylesheet",a.href="https://maxcdn.bootstrapcdn.com/font-awesome/latest/css/font-awesome.min.css",document.getElementsByTagName("head")[0].appendChild(a)}if(e.element)this.element=e.element;else if(e.element===null){console.log("EasyMDE: Error. No element was found.");return}if(e.toolbar===void 0){e.toolbar=[];for(var o in Ms)Object.prototype.hasOwnProperty.call(Ms,o)&&(o.indexOf("separator-")!=-1&&e.toolbar.push("|"),(Ms[o].default===!0||e.showIcons&&e.showIcons.constructor===Array&&e.showIcons.indexOf(o)!=-1)&&e.toolbar.push(o))}if(Object.prototype.hasOwnProperty.call(e,"previewClass")||(e.previewClass="editor-preview"),Object.prototype.hasOwnProperty.call(e,"status")||(e.status=["autosave","lines","words","cursor"],e.uploadImage&&e.status.unshift("upload-image")),e.previewRender||(e.previewRender=function(u){return this.parent.markdown(u)}),e.parsingConfig=go({highlightFormatting:!0},e.parsingConfig||{}),e.insertTexts=go({},jB,e.insertTexts||{}),e.promptTexts=go({},XB,e.promptTexts||{}),e.blockStyles=go({},JB,e.blockStyles||{}),e.autosave!=null&&(e.autosave.timeFormat=go({},ZB,e.autosave.timeFormat||{})),e.iconClassMap=go({},In,e.iconClassMap||{}),e.shortcuts=go({},qB,e.shortcuts||{}),e.maxHeight=e.maxHeight||void 0,e.direction=e.direction||"ltr",typeof e.maxHeight<"u"?e.minHeight=e.maxHeight:e.minHeight=e.minHeight||"300px",e.errorCallback=e.errorCallback||function(u){alert(u)},e.uploadImage=e.uploadImage||!1,e.imageMaxSize=e.imageMaxSize||2097152,e.imageAccept=e.imageAccept||"image/png, image/jpeg, image/gif, image/avif",e.imageTexts=go({},eU,e.imageTexts||{}),e.errorMessages=go({},tU,e.errorMessages||{}),e.imagePathAbsolute=e.imagePathAbsolute||!1,e.imageCSRFName=e.imageCSRFName||"csrfmiddlewaretoken",e.imageCSRFHeader=e.imageCSRFHeader||!1,e.autosave!=null&&e.autosave.unique_id!=null&&e.autosave.unique_id!=""&&(e.autosave.uniqueId=e.autosave.unique_id),e.overlayMode&&e.overlayMode.combine===void 0&&(e.overlayMode.combine=!0),this.options=e,this.render(),e.initialValue&&(!this.options.autosave||this.options.autosave.foundSavedValue!==!0)&&this.value(e.initialValue),e.uploadImage){var l=this;this.codemirror.on("dragenter",function(u,c){l.updateStatusBar("upload-image",l.options.imageTexts.sbOnDragEnter),c.stopPropagation(),c.preventDefault()}),this.codemirror.on("dragend",function(u,c){l.updateStatusBar("upload-image",l.options.imageTexts.sbInit),c.stopPropagation(),c.preventDefault()}),this.codemirror.on("dragleave",function(u,c){l.updateStatusBar("upload-image",l.options.imageTexts.sbInit),c.stopPropagation(),c.preventDefault()}),this.codemirror.on("dragover",function(u,c){l.updateStatusBar("upload-image",l.options.imageTexts.sbOnDragEnter),c.stopPropagation(),c.preventDefault()}),this.codemirror.on("drop",function(u,c){c.stopPropagation(),c.preventDefault(),e.imageUploadFunction?l.uploadImagesUsingCustomFunction(e.imageUploadFunction,c.dataTransfer.files):l.uploadImages(c.dataTransfer.files)}),this.codemirror.on("paste",function(u,c){e.imageUploadFunction?l.uploadImagesUsingCustomFunction(e.imageUploadFunction,c.clipboardData.files):l.uploadImages(c.clipboardData.files)})}}It.prototype.uploadImages=function(e,t,n){if(e.length!==0){for(var r=[],a=0;a<e.length;a++)r.push(e[a].name),this.uploadImage(e[a],t,n);this.updateStatusBar("upload-image",this.options.imageTexts.sbOnDrop.replace("#images_names#",r.join(", ")))}};It.prototype.uploadImagesUsingCustomFunction=function(e,t){if(t.length!==0){for(var n=[],r=0;r<t.length;r++)n.push(t[r].name),this.uploadImageUsingCustomFunction(e,t[r]);this.updateStatusBar("upload-image",this.options.imageTexts.sbOnDrop.replace("#images_names#",n.join(", ")))}};It.prototype.updateStatusBar=function(e,t){if(!!this.gui.statusbar){var n=this.gui.statusbar.getElementsByClassName(e);n.length===1?this.gui.statusbar.getElementsByClassName(e)[0].textContent=t:n.length===0?console.log("EasyMDE: status bar item "+e+" was not found."):console.log("EasyMDE: Several status bar items named "+e+" was found.")}};It.prototype.markdown=function(e){if(Zg){var t;if(this.options&&this.options.renderingConfig&&this.options.renderingConfig.markedOptions?t=this.options.renderingConfig.markedOptions:t={},this.options&&this.options.renderingConfig&&this.options.renderingConfig.singleLineBreaks===!1?t.breaks=!1:t.breaks=!0,this.options&&this.options.renderingConfig&&this.options.renderingConfig.codeSyntaxHighlighting===!0){var n=this.options.renderingConfig.hljs||window.hljs;n&&(t.highlight=function(a,o){return o&&n.getLanguage(o)?n.highlight(o,a).value:n.highlightAuto(a).value})}Zg.setOptions(t);var r=Zg.parse(e);return this.options.renderingConfig&&typeof this.options.renderingConfig.sanitizerFunction=="function"&&(r=this.options.renderingConfig.sanitizerFunction.call(this,r)),r=WB(r),r=VB(r),r}};It.prototype.render=function(e){if(e||(e=this.element||document.getElementsByTagName("textarea")[0]),this._rendered&&this._rendered===e)return;this.element=e;var t=this.options,n=this,r={};for(var a in t.shortcuts)t.shortcuts[a]!==null&&Ku[a]!==null&&function(v){r[fR(t.shortcuts[v])]=function(){var A=Ku[v];typeof A=="function"?A(n):typeof A=="string"&&window.open(A,"_blank")}}(a);r.Enter="newlineAndIndentContinueMarkdownList",r.Tab="tabAndIndentMarkdownList",r["Shift-Tab"]="shiftTabAndUnindentMarkdownList",r.Esc=function(v){v.getOption("fullScreen")&&zs(n)},this.documentOnKeyDown=function(v){v=v||window.event,v.keyCode==27&&n.codemirror.getOption("fullScreen")&&zs(n)},document.addEventListener("keydown",this.documentOnKeyDown,!1);var o,l;t.overlayMode?(vl.defineMode("overlay-mode",function(v){return vl.overlayMode(vl.getMode(v,t.spellChecker!==!1?"spell-checker":"gfm"),t.overlayMode.mode,t.overlayMode.combine)}),o="overlay-mode",l=t.parsingConfig,l.gitHubSpice=!1):(o=t.parsingConfig,o.name="gfm",o.gitHubSpice=!1),t.spellChecker!==!1&&(o="spell-checker",l=t.parsingConfig,l.name="gfm",l.gitHubSpice=!1,typeof t.spellChecker=="function"?t.spellChecker({codeMirrorInstance:vl}):GB({codeMirrorInstance:vl}));function u(v,A,O){return{addNew:!1}}if(this.codemirror=vl.fromTextArea(e,{mode:o,backdrop:l,theme:t.theme!=null?t.theme:"easymde",tabSize:t.tabSize!=null?t.tabSize:2,indentUnit:t.tabSize!=null?t.tabSize:2,indentWithTabs:t.indentWithTabs!==!1,lineNumbers:t.lineNumbers===!0,autofocus:t.autofocus===!0,extraKeys:r,direction:t.direction,lineWrapping:t.lineWrapping!==!1,allowDropFileTypes:["text/plain"],placeholder:t.placeholder||e.getAttribute("placeholder")||"",styleSelectedText:t.styleSelectedText!=null?t.styleSelectedText:!wh(),scrollbarStyle:t.scrollbarStyle!=null?t.scrollbarStyle:"native",configureMouse:u,inputStyle:t.inputStyle!=null?t.inputStyle:wh()?"contenteditable":"textarea",spellcheck:t.nativeSpellcheck!=null?t.nativeSpellcheck:!0,autoRefresh:t.autoRefresh!=null?t.autoRefresh:!1}),this.codemirror.getScrollerElement().style.minHeight=t.minHeight,typeof t.maxHeight<"u"&&(this.codemirror.getScrollerElement().style.height=t.maxHeight),t.forceSync===!0){var c=this.codemirror;c.on("change",function(){c.save()})}this.gui={};var d=document.createElement("div");d.classList.add("EasyMDEContainer"),d.setAttribute("role","application");var S=this.codemirror.getWrapperElement();S.parentNode.insertBefore(d,S),d.appendChild(S),t.toolbar!==!1&&(this.gui.toolbar=this.createToolbar()),t.status!==!1&&(this.gui.statusbar=this.createStatusbar()),t.autosave!=null&&t.autosave.enabled===!0&&(this.autosave(),this.codemirror.on("change",function(){clearTimeout(n._autosave_timeout),n._autosave_timeout=setTimeout(function(){n.autosave()},n.options.autosave.submit_delay||n.options.autosave.delay||1e3)}));function _(v,A){var O,N=window.getComputedStyle(document.querySelector(".CodeMirror-sizer")).width.replace("px","");return v<N?O=A+"px":O=A/v*100+"%",O}var E=this;function T(v,A){v.setAttribute("data-img-src",A.url),v.setAttribute("style","--bg-image:url("+A.url+");--width:"+A.naturalWidth+"px;--height:"+_(A.naturalWidth,A.naturalHeight)),E.codemirror.setSize()}function y(){!t.previewImagesInEditor||d.querySelectorAll(".cm-image-marker").forEach(function(v){var A=v.parentElement;if(!!A.innerText.match(/^!\[.*?\]\(.*\)/g)&&!A.hasAttribute("data-img-src")){var O=A.innerText.match("\\((.*)\\)");if(window.EMDEimagesCache||(window.EMDEimagesCache={}),O&&O.length>=2){var N=O[1];if(t.imagesPreviewHandler){var R=t.imagesPreviewHandler(O[1]);typeof R=="string"&&(N=R)}if(window.EMDEimagesCache[N])T(A,window.EMDEimagesCache[N]);else{var L=document.createElement("img");L.onload=function(){window.EMDEimagesCache[N]={naturalWidth:L.naturalWidth,naturalHeight:L.naturalHeight,url:N},T(A,window.EMDEimagesCache[N])},L.src=N}}}})}this.codemirror.on("update",function(){y()}),this.gui.sideBySide=this.createSideBySide(),this._rendered=this.element,(t.autofocus===!0||e.autofocus)&&this.codemirror.focus();var M=this.codemirror;setTimeout(function(){M.refresh()}.bind(M),0)};It.prototype.cleanup=function(){document.removeEventListener("keydown",this.documentOnKeyDown)};function hR(){if(typeof localStorage=="object")try{localStorage.setItem("smde_localStorage",1),localStorage.removeItem("smde_localStorage")}catch{return!1}else return!1;return!0}It.prototype.autosave=function(){if(hR()){var e=this;if(this.options.autosave.uniqueId==null||this.options.autosave.uniqueId==""){console.log("EasyMDE: You must set a uniqueId to use the autosave feature");return}this.options.autosave.binded!==!0&&(e.element.form!=null&&e.element.form!=null&&e.element.form.addEventListener("submit",function(){clearTimeout(e.autosaveTimeoutId),e.autosaveTimeoutId=void 0,localStorage.removeItem("smde_"+e.options.autosave.uniqueId)}),this.options.autosave.binded=!0),this.options.autosave.loaded!==!0&&(typeof localStorage.getItem("smde_"+this.options.autosave.uniqueId)=="string"&&localStorage.getItem("smde_"+this.options.autosave.uniqueId)!=""&&(this.codemirror.setValue(localStorage.getItem("smde_"+this.options.autosave.uniqueId)),this.options.autosave.foundSavedValue=!0),this.options.autosave.loaded=!0);var t=e.value();t!==""?localStorage.setItem("smde_"+this.options.autosave.uniqueId,t):localStorage.removeItem("smde_"+this.options.autosave.uniqueId);var n=document.getElementById("autosaved");if(n!=null&&n!=null&&n!=""){var r=new Date,a=new Intl.DateTimeFormat([this.options.autosave.timeFormat.locale,"en-US"],this.options.autosave.timeFormat.format).format(r),o=this.options.autosave.text==null?"Autosaved: ":this.options.autosave.text;n.innerHTML=o+a}}else console.log("EasyMDE: localStorage not available, cannot autosave")};It.prototype.clearAutosavedValue=function(){if(hR()){if(this.options.autosave==null||this.options.autosave.uniqueId==null||this.options.autosave.uniqueId==""){console.log("EasyMDE: You must set a uniqueId to clear the autosave value");return}localStorage.removeItem("smde_"+this.options.autosave.uniqueId)}else console.log("EasyMDE: localStorage not available, cannot autosave")};It.prototype.openBrowseFileWindow=function(e,t){var n=this,r=this.gui.toolbar.getElementsByClassName("imageInput")[0];r.click();function a(o){n.options.imageUploadFunction?n.uploadImagesUsingCustomFunction(n.options.imageUploadFunction,o.target.files):n.uploadImages(o.target.files,e,t),r.removeEventListener("change",a)}r.addEventListener("change",a)};It.prototype.uploadImage=function(e,t,n){var r=this;t=t||function(d){_R(r,d)};function a(c){r.updateStatusBar("upload-image",c),setTimeout(function(){r.updateStatusBar("upload-image",r.options.imageTexts.sbInit)},1e4),n&&typeof n=="function"&&n(c),r.options.errorCallback(c)}function o(c){var d=r.options.imageTexts.sizeUnits.split(",");return c.replace("#image_name#",e.name).replace("#image_size#",yd(e.size,d)).replace("#image_max_size#",yd(r.options.imageMaxSize,d))}if(e.size>this.options.imageMaxSize){a(o(this.options.errorMessages.fileTooLarge));return}var l=new FormData;l.append("image",e),r.options.imageCSRFToken&&!r.options.imageCSRFHeader&&l.append(r.options.imageCSRFName,r.options.imageCSRFToken);var u=new XMLHttpRequest;u.upload.onprogress=function(c){if(c.lengthComputable){var d=""+Math.round(c.loaded*100/c.total);r.updateStatusBar("upload-image",r.options.imageTexts.sbProgress.replace("#file_name#",e.name).replace("#progress#",d))}},u.open("POST",this.options.imageUploadEndpoint),r.options.imageCSRFToken&&r.options.imageCSRFHeader&&u.setRequestHeader(r.options.imageCSRFName,r.options.imageCSRFToken),u.onload=function(){try{var c=JSON.parse(this.responseText)}catch{console.error("EasyMDE: The server did not return a valid json."),a(o(r.options.errorMessages.importError));return}this.status===200&&c&&!c.error&&c.data&&c.data.filePath?t((r.options.imagePathAbsolute?"":window.location.origin+"/")+c.data.filePath):c.error&&c.error in r.options.errorMessages?a(o(r.options.errorMessages[c.error])):c.error?a(o(c.error)):(console.error("EasyMDE: Received an unexpected response after uploading the image."+this.status+" ("+this.statusText+")"),a(o(r.options.errorMessages.importError)))},u.onerror=function(c){console.error("EasyMDE: An unexpected error occurred when trying to upload the image."+c.target.status+" ("+c.target.statusText+")"),a(r.options.errorMessages.importError)},u.send(l)};It.prototype.uploadImageUsingCustomFunction=function(e,t){var n=this;function r(l){_R(n,l)}function a(l){var u=o(l);n.updateStatusBar("upload-image",u),setTimeout(function(){n.updateStatusBar("upload-image",n.options.imageTexts.sbInit)},1e4),n.options.errorCallback(u)}function o(l){var u=n.options.imageTexts.sizeUnits.split(",");return l.replace("#image_name#",t.name).replace("#image_size#",yd(t.size,u)).replace("#image_max_size#",yd(n.options.imageMaxSize,u))}e.apply(this,[t,r,a])};It.prototype.setPreviewMaxHeight=function(){var e=this.codemirror,t=e.getWrapperElement(),n=t.nextSibling,r=parseInt(window.getComputedStyle(t).paddingTop),a=parseInt(window.getComputedStyle(t).borderTopWidth),o=parseInt(this.options.maxHeight),l=o+r*2+a*2,u=l.toString()+"px";n.style.height=u};It.prototype.createSideBySide=function(){var e=this.codemirror,t=e.getWrapperElement(),n=t.nextSibling;if(!n||!n.classList.contains("editor-preview-side")){if(n=document.createElement("div"),n.className="editor-preview-side",this.options.previewClass)if(Array.isArray(this.options.previewClass))for(var r=0;r<this.options.previewClass.length;r++)n.classList.add(this.options.previewClass[r]);else typeof this.options.previewClass=="string"&&n.classList.add(this.options.previewClass);t.parentNode.insertBefore(n,t.nextSibling)}if(typeof this.options.maxHeight<"u"&&this.setPreviewMaxHeight(),this.options.syncSideBySidePreviewScroll===!1)return n;var a=!1,o=!1;return e.on("scroll",function(l){if(a){a=!1;return}o=!0;var u=l.getScrollInfo().height-l.getScrollInfo().clientHeight,c=parseFloat(l.getScrollInfo().top)/u,d=(n.scrollHeight-n.clientHeight)*c;n.scrollTop=d}),n.onscroll=function(){if(o){o=!1;return}a=!0;var l=n.scrollHeight-n.clientHeight,u=parseFloat(n.scrollTop)/l,c=(e.getScrollInfo().height-e.getScrollInfo().clientHeight)*u;e.scrollTo(0,c)},n};It.prototype.createToolbar=function(e){if(e=e||this.options.toolbar,!(!e||e.length===0)){var t;for(t=0;t<e.length;t++)Ms[e[t]]!=null&&(e[t]=Ms[e[t]]);var n=document.createElement("div");n.className="editor-toolbar",n.setAttribute("role","toolbar");var r=this,a={};for(r.toolbar=e,t=0;t<e.length;t++)if(!(e[t].name=="guide"&&r.options.toolbarGuideIcon===!1)&&!(r.options.hideIcons&&r.options.hideIcons.indexOf(e[t].name)!=-1)&&!((e[t].name=="fullscreen"||e[t].name=="side-by-side")&&wh())){if(e[t]==="|"){for(var o=!1,l=t+1;l<e.length;l++)e[l]!=="|"&&(!r.options.hideIcons||r.options.hideIcons.indexOf(e[l].name)==-1)&&(o=!0);if(!o)continue}(function(d){var S;if(d==="|"?S=KB():d.children?S=zB(d,r.options.toolbarTips,r.options.shortcuts,r):S=fd(d,!0,r.options.toolbarTips,r.options.shortcuts,"button",r),a[d.name||d]=S,n.appendChild(S),d.name==="upload-image"){var _=document.createElement("input");_.className="imageInput",_.type="file",_.multiple=!0,_.name="image",_.accept=r.options.imageAccept,_.style.display="none",_.style.opacity=0,n.appendChild(_)}})(e[t])}r.toolbar_div=n,r.toolbarElements=a;var u=this.codemirror;u.on("cursorActivity",function(){var d=ds(u);for(var S in a)(function(_){var E=a[_];d[_]?E.classList.add("active"):_!="fullscreen"&&_!="side-by-side"&&E.classList.remove("active")})(S)});var c=u.getWrapperElement();return c.parentNode.insertBefore(n,c),n}};It.prototype.createStatusbar=function(e){e=e||this.options.status;var t=this.options,n=this.codemirror;if(!(!e||e.length===0)){var r=[],a,o,l,u;for(a=0;a<e.length;a++)if(o=void 0,l=void 0,u=void 0,typeof e[a]=="object")r.push({className:e[a].className,defaultValue:e[a].defaultValue,onUpdate:e[a].onUpdate,onActivity:e[a].onActivity});else{var c=e[a];c==="words"?(u=function(T){T.innerHTML=uC(n.getValue())},o=function(T){T.innerHTML=uC(n.getValue())}):c==="lines"?(u=function(T){T.innerHTML=n.lineCount()},o=function(T){T.innerHTML=n.lineCount()}):c==="cursor"?(u=function(T){T.innerHTML="1:1"},l=function(T){var y=n.getCursor(),M=y.line+1,v=y.ch+1;T.innerHTML=M+":"+v}):c==="autosave"?u=function(T){t.autosave!=null&&t.autosave.enabled===!0&&T.setAttribute("id","autosaved")}:c==="upload-image"&&(u=function(T){T.innerHTML=t.imageTexts.sbInit}),r.push({className:c,defaultValue:u,onUpdate:o,onActivity:l})}var d=document.createElement("div");for(d.className="editor-statusbar",a=0;a<r.length;a++){var S=r[a],_=document.createElement("span");_.className=S.className,typeof S.defaultValue=="function"&&S.defaultValue(_),typeof S.onUpdate=="function"&&this.codemirror.on("update",function(T,y){return function(){y.onUpdate(T)}}(_,S)),typeof S.onActivity=="function"&&this.codemirror.on("cursorActivity",function(T,y){return function(){y.onActivity(T)}}(_,S)),d.appendChild(_)}var E=this.codemirror.getWrapperElement();return E.parentNode.insertBefore(d,E.nextSibling),d}};It.prototype.value=function(e){var t=this.codemirror;if(e===void 0)return t.getValue();if(t.getDoc().setValue(e),this.isPreviewActive()){var n=t.getWrapperElement(),r=n.lastChild,a=this.options.previewRender(e,r);a!==null&&(r.innerHTML=a)}return this};It.toggleBold=jd;It.toggleItalic=Xd;It.toggleStrikethrough=Zd;It.toggleBlockquote=ef;It.toggleHeadingSmaller=$u;It.toggleHeadingBigger=tf;It.toggleHeading1=nf;It.toggleHeading2=rf;It.toggleHeading3=af;It.toggleHeading4=FE;It.toggleHeading5=BE;It.toggleHeading6=UE;It.toggleCodeBlock=Jd;It.toggleUnorderedList=of;It.toggleOrderedList=sf;It.cleanBlock=lf;It.drawLink=uf;It.drawImage=cf;It.drawUploadedImage=GE;It.drawTable=df;It.drawHorizontalRule=ff;It.undo=pf;It.redo=_f;It.togglePreview=mf;It.toggleSideBySide=Zl;It.toggleFullScreen=zs;It.prototype.toggleBold=function(){jd(this)};It.prototype.toggleItalic=function(){Xd(this)};It.prototype.toggleStrikethrough=function(){Zd(this)};It.prototype.toggleBlockquote=function(){ef(this)};It.prototype.toggleHeadingSmaller=function(){$u(this)};It.prototype.toggleHeadingBigger=function(){tf(this)};It.prototype.toggleHeading1=function(){nf(this)};It.prototype.toggleHeading2=function(){rf(this)};It.prototype.toggleHeading3=function(){af(this)};It.prototype.toggleHeading4=function(){FE(this)};It.prototype.toggleHeading5=function(){BE(this)};It.prototype.toggleHeading6=function(){UE(this)};It.prototype.toggleCodeBlock=function(){Jd(this)};It.prototype.toggleUnorderedList=function(){of(this)};It.prototype.toggleOrderedList=function(){sf(this)};It.prototype.cleanBlock=function(){lf(this)};It.prototype.drawLink=function(){uf(this)};It.prototype.drawImage=function(){cf(this)};It.prototype.drawUploadedImage=function(){GE(this)};It.prototype.drawTable=function(){df(this)};It.prototype.drawHorizontalRule=function(){ff(this)};It.prototype.undo=function(){pf(this)};It.prototype.redo=function(){_f(this)};It.prototype.togglePreview=function(){mf(this)};It.prototype.toggleSideBySide=function(){Zl(this)};It.prototype.toggleFullScreen=function(){zs(this)};It.prototype.isPreviewActive=function(){var e=this.codemirror,t=e.getWrapperElement(),n=t.lastChild;return n.classList.contains("editor-preview-active")};It.prototype.isSideBySideActive=function(){var e=this.codemirror,t=e.getWrapperElement(),n=t.nextSibling;return n.classList.contains("editor-preview-active-side")};It.prototype.isFullscreenActive=function(){var e=this.codemirror;return e.getOption("fullScreen")};It.prototype.getState=function(){var e=this.codemirror;return ds(e)};It.prototype.toTextArea=function(){var e=this.codemirror,t=e.getWrapperElement(),n=t.parentNode;n&&(this.gui.toolbar&&n.removeChild(this.gui.toolbar),this.gui.statusbar&&n.removeChild(this.gui.statusbar),this.gui.sideBySide&&n.removeChild(this.gui.sideBySide)),n.parentNode.insertBefore(t,n),n.remove(),e.toTextArea(),this.autosaveTimeoutId&&(clearTimeout(this.autosaveTimeoutId),this.autosaveTimeoutId=void 0,this.clearAutosavedValue())};var nU=It;function Jl(e,t){const n=Object.create(null),r=e.split(",");for(let a=0;a<r.length;a++)n[r[a]]=!0;return t?a=>!!n[a.toLowerCase()]:a=>!!n[a]}const yn={},Ol=[],vi=()=>{},rU=()=>!1,iU=/^on[^a-z]/,Co=e=>iU.test(e),YE=e=>e.startsWith("onUpdate:"),sn=Object.assign,WE=(e,t)=>{const n=e.indexOf(t);n>-1&&e.splice(n,1)},aU=Object.prototype.hasOwnProperty,_n=(e,t)=>aU.call(e,t),Rt=Array.isArray,Rl=e=>eu(e)==="[object Map]",Js=e=>eu(e)==="[object Set]",cC=e=>eu(e)==="[object Date]",oU=e=>eu(e)==="[object RegExp]",Ft=e=>typeof e=="function",xn=e=>typeof e=="string",Ul=e=>typeof e=="symbol",ln=e=>e!==null&&typeof e=="object",gf=e=>(ln(e)||Ft(e))&&Ft(e.then)&&Ft(e.catch),ER=Object.prototype.toString,eu=e=>ER.call(e),sU=e=>eu(e).slice(8,-1),Cd=e=>eu(e)==="[object Object]",VE=e=>xn(e)&&e!=="NaN"&&e[0]!=="-"&&""+parseInt(e,10)===e,Nl=Jl(",key,ref,ref_for,ref_key,onVnodeBeforeMount,onVnodeMounted,onVnodeBeforeUpdate,onVnodeUpdated,onVnodeBeforeUnmount,onVnodeUnmounted"),hf=e=>{const t=Object.create(null);return n=>t[n]||(t[n]=e(n))},lU=/-(\w)/g,ni=hf(e=>e.replace(lU,(t,n)=>n?n.toUpperCase():"")),uU=/\B([A-Z])/g,ei=hf(e=>e.replace(uU,"-$1").toLowerCase()),gc=hf(e=>e.charAt(0).toUpperCase()+e.slice(1)),Il=hf(e=>e?`on${gc(e)}`:""),os=(e,t)=>!Object.is(e,t),Jo=(e,t)=>{for(let n=0;n<e.length;n++)e[n](t)},Ad=(e,t,n)=>{Object.defineProperty(e,t,{configurable:!0,enumerable:!1,value:n})},Qu=e=>{const t=parseFloat(e);return isNaN(t)?e:t},Od=e=>{const t=xn(e)?Number(e):NaN;return isNaN(t)?e:t};let dC;const Lh=()=>dC||(dC=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:typeof global<"u"?global:{}),cU="Infinity,undefined,NaN,isFinite,isNaN,parseFloat,parseInt,decodeURI,decodeURIComponent,encodeURI,encodeURIComponent,Math,Number,Date,Array,Object,Boolean,String,RegExp,Map,Set,JSON,Intl,BigInt,console",dU=Jl(cU);function tu(e){if(Rt(e)){const t={};for(let n=0;n<e.length;n++){const r=e[n],a=xn(r)?mU(r):tu(r);if(a)for(const o in a)t[o]=a[o]}return t}else if(xn(e)||ln(e))return e}const fU=/;(?![^(]*\))/g,pU=/:([^]+)/,_U=/\/\*[^]*?\*\//g;function mU(e){const t={};return e.replace(_U,"").split(fU).forEach(n=>{if(n){const r=n.split(pU);r.length>1&&(t[r[0].trim()]=r[1].trim())}}),t}function Va(e){let t="";if(xn(e))t=e;else if(Rt(e))for(let n=0;n<e.length;n++){const r=Va(e[n]);r&&(t+=r+" ")}else if(ln(e))for(const n in e)e[n]&&(t+=n+" ");return t.trim()}function gU(e){if(!e)return null;let{class:t,style:n}=e;return t&&!xn(t)&&(e.class=Va(t)),n&&(e.style=tu(n)),e}const hU="itemscope,allowfullscreen,formnovalidate,ismap,nomodule,novalidate,readonly",SR=Jl(hU);function bR(e){return!!e||e===""}function EU(e,t){if(e.length!==t.length)return!1;let n=!0;for(let r=0;n&&r<e.length;r++)n=To(e[r],t[r]);return n}function To(e,t){if(e===t)return!0;let n=cC(e),r=cC(t);if(n||r)return n&&r?e.getTime()===t.getTime():!1;if(n=Ul(e),r=Ul(t),n||r)return e===t;if(n=Rt(e),r=Rt(t),n||r)return n&&r?EU(e,t):!1;if(n=ln(e),r=ln(t),n||r){if(!n||!r)return!1;const a=Object.keys(e).length,o=Object.keys(t).length;if(a!==o)return!1;for(const l in e){const u=e.hasOwnProperty(l),c=t.hasOwnProperty(l);if(u&&!c||!u&&c||!To(e[l],t[l]))return!1}}return String(e)===String(t)}function hc(e,t){return e.findIndex(n=>To(n,t))}const Rd=e=>xn(e)?e:e==null?"":Rt(e)||ln(e)&&(e.toString===ER||!Ft(e.toString))?JSON.stringify(e,vR,2):String(e),vR=(e,t)=>t&&t.__v_isRef?vR(e,t.value):Rl(t)?{[`Map(${t.size})`]:[...t.entries()].reduce((n,[r,a])=>(n[`${r} =>`]=a,n),{})}:Js(t)?{[`Set(${t.size})`]:[...t.values()]}:ln(t)&&!Rt(t)&&!Cd(t)?String(t):t;let Mi;class zE{constructor(t=!1){this.detached=t,this._active=!0,this.effects=[],this.cleanups=[],this.parent=Mi,!t&&Mi&&(this.index=(Mi.scopes||(Mi.scopes=[])).push(this)-1)}get active(){return this._active}run(t){if(this._active){const n=Mi;try{return Mi=this,t()}finally{Mi=n}}}on(){Mi=this}off(){Mi=this.parent}stop(t){if(this._active){let n,r;for(n=0,r=this.effects.length;n<r;n++)this.effects[n].stop();for(n=0,r=this.cleanups.length;n<r;n++)this.cleanups[n]();if(this.scopes)for(n=0,r=this.scopes.length;n<r;n++)this.scopes[n].stop(!0);if(!this.detached&&this.parent&&!t){const a=this.parent.scopes.pop();a&&a!==this&&(this.parent.scopes[this.index]=a,a.index=this.index)}this.parent=void 0,this._active=!1}}}function SU(e){return new zE(e)}function TR(e,t=Mi){t&&t.active&&t.effects.push(e)}function yR(){return Mi}function bU(e){Mi&&Mi.cleanups.push(e)}const KE=e=>{const t=new Set(e);return t.w=0,t.n=0,t},CR=e=>(e.w&ss)>0,AR=e=>(e.n&ss)>0,vU=({deps:e})=>{if(e.length)for(let t=0;t<e.length;t++)e[t].w|=ss},TU=e=>{const{deps:t}=e;if(t.length){let n=0;for(let r=0;r<t.length;r++){const a=t[r];CR(a)&&!AR(a)?a.delete(e):t[n++]=a,a.w&=~ss,a.n&=~ss}t.length=n}},Nd=new WeakMap;let Du=0,ss=1;const Mh=30;let Sa;const ks=Symbol(""),kh=Symbol("");class Gl{constructor(t,n=null,r){this.fn=t,this.scheduler=n,this.active=!0,this.deps=[],this.parent=void 0,TR(this,r)}run(){if(!this.active)return this.fn();let t=Sa,n=es;for(;t;){if(t===this)return;t=t.parent}try{return this.parent=Sa,Sa=this,es=!0,ss=1<<++Du,Du<=Mh?vU(this):fC(this),this.fn()}finally{Du<=Mh&&TU(this),ss=1<<--Du,Sa=this.parent,es=n,this.parent=void 0,this.deferStop&&this.stop()}}stop(){Sa===this?this.deferStop=!0:this.active&&(fC(this),this.onStop&&this.onStop(),this.active=!1)}}function fC(e){const{deps:t}=e;if(t.length){for(let n=0;n<t.length;n++)t[n].delete(e);t.length=0}}function yU(e,t){e.effect instanceof Gl&&(e=e.effect.fn);const n=new Gl(e);t&&(sn(n,t),t.scope&&TR(n,t.scope)),(!t||!t.lazy)&&n.run();const r=n.run.bind(n);return r.effect=n,r}function CU(e){e.effect.stop()}let es=!0;const OR=[];function nu(){OR.push(es),es=!1}function ru(){const e=OR.pop();es=e===void 0?!0:e}function ri(e,t,n){if(es&&Sa){let r=Nd.get(e);r||Nd.set(e,r=new Map);let a=r.get(n);a||r.set(n,a=KE()),RR(a)}}function RR(e,t){let n=!1;Du<=Mh?AR(e)||(e.n|=ss,n=!CR(e)):n=!e.has(Sa),n&&(e.add(Sa),Sa.deps.push(e))}function qa(e,t,n,r,a,o){const l=Nd.get(e);if(!l)return;let u=[];if(t==="clear")u=[...l.values()];else if(n==="length"&&Rt(e)){const c=Number(r);l.forEach((d,S)=>{(S==="length"||!Ul(S)&&S>=c)&&u.push(d)})}else switch(n!==void 0&&u.push(l.get(n)),t){case"add":Rt(e)?VE(n)&&u.push(l.get("length")):(u.push(l.get(ks)),Rl(e)&&u.push(l.get(kh)));break;case"delete":Rt(e)||(u.push(l.get(ks)),Rl(e)&&u.push(l.get(kh)));break;case"set":Rl(e)&&u.push(l.get(ks));break}if(u.length===1)u[0]&&Ph(u[0]);else{const c=[];for(const d of u)d&&c.push(...d);Ph(KE(c))}}function Ph(e,t){const n=Rt(e)?e:[...e];for(const r of n)r.computed&&pC(r);for(const r of n)r.computed||pC(r)}function pC(e,t){(e!==Sa||e.allowRecurse)&&(e.scheduler?e.scheduler():e.run())}function AU(e,t){var n;return(n=Nd.get(e))==null?void 0:n.get(t)}const OU=Jl("__proto__,__v_isRef,__isVue"),NR=new Set(Object.getOwnPropertyNames(Symbol).filter(e=>e!=="arguments"&&e!=="caller").map(e=>Symbol[e]).filter(Ul)),_C=RU();function RU(){const e={};return["includes","indexOf","lastIndexOf"].forEach(t=>{e[t]=function(...n){const r=pn(this);for(let o=0,l=this.length;o<l;o++)ri(r,"get",o+"");const a=r[t](...n);return a===-1||a===!1?r[t](...n.map(pn)):a}}),["push","pop","shift","unshift","splice"].forEach(t=>{e[t]=function(...n){nu();const r=pn(this)[t].apply(this,n);return ru(),r}}),e}function NU(e){const t=pn(this);return ri(t,"has",e),t.hasOwnProperty(e)}class IR{constructor(t=!1,n=!1){this._isReadonly=t,this._shallow=n}get(t,n,r){const a=this._isReadonly,o=this._shallow;if(n==="__v_isReactive")return!a;if(n==="__v_isReadonly")return a;if(n==="__v_isShallow")return o;if(n==="__v_raw"&&r===(a?o?kR:MR:o?LR:wR).get(t))return t;const l=Rt(t);if(!a){if(l&&_n(_C,n))return Reflect.get(_C,n,r);if(n==="hasOwnProperty")return NU}const u=Reflect.get(t,n,r);return(Ul(n)?NR.has(n):OU(n))||(a||ri(t,"get",n),o)?u:sr(u)?l&&VE(n)?u:u.value:ln(u)?a?QE(u):ls(u):u}}class DR extends IR{constructor(t=!1){super(!1,t)}set(t,n,r,a){let o=t[n];if($s(o)&&sr(o)&&!sr(r))return!1;if(!this._shallow&&(!ju(r)&&!$s(r)&&(o=pn(o),r=pn(r)),!Rt(t)&&sr(o)&&!sr(r)))return o.value=r,!0;const l=Rt(t)&&VE(n)?Number(n)<t.length:_n(t,n),u=Reflect.set(t,n,r,a);return t===pn(a)&&(l?os(r,o)&&qa(t,"set",n,r):qa(t,"add",n,r)),u}deleteProperty(t,n){const r=_n(t,n);t[n];const a=Reflect.deleteProperty(t,n);return a&&r&&qa(t,"delete",n,void 0),a}has(t,n){const r=Reflect.has(t,n);return(!Ul(n)||!NR.has(n))&&ri(t,"has",n),r}ownKeys(t){return ri(t,"iterate",Rt(t)?"length":ks),Reflect.ownKeys(t)}}class xR extends IR{constructor(t=!1){super(!0,t)}set(t,n){return!0}deleteProperty(t,n){return!0}}const IU=new DR,DU=new xR,xU=new DR(!0),wU=new xR(!0),$E=e=>e,Ef=e=>Reflect.getPrototypeOf(e);function Xc(e,t,n=!1,r=!1){e=e.__v_raw;const a=pn(e),o=pn(t);n||(os(t,o)&&ri(a,"get",t),ri(a,"get",o));const{has:l}=Ef(a),u=r?$E:n?ZE:Xu;if(l.call(a,t))return u(e.get(t));if(l.call(a,o))return u(e.get(o));e!==a&&e.get(t)}function Zc(e,t=!1){const n=this.__v_raw,r=pn(n),a=pn(e);return t||(os(e,a)&&ri(r,"has",e),ri(r,"has",a)),e===a?n.has(e):n.has(e)||n.has(a)}function Jc(e,t=!1){return e=e.__v_raw,!t&&ri(pn(e),"iterate",ks),Reflect.get(e,"size",e)}function mC(e){e=pn(e);const t=pn(this);return Ef(t).has.call(t,e)||(t.add(e),qa(t,"add",e,e)),this}function gC(e,t){t=pn(t);const n=pn(this),{has:r,get:a}=Ef(n);let o=r.call(n,e);o||(e=pn(e),o=r.call(n,e));const l=a.call(n,e);return n.set(e,t),o?os(t,l)&&qa(n,"set",e,t):qa(n,"add",e,t),this}function hC(e){const t=pn(this),{has:n,get:r}=Ef(t);let a=n.call(t,e);a||(e=pn(e),a=n.call(t,e)),r&&r.call(t,e);const o=t.delete(e);return a&&qa(t,"delete",e,void 0),o}function EC(){const e=pn(this),t=e.size!==0,n=e.clear();return t&&qa(e,"clear",void 0,void 0),n}function ed(e,t){return function(r,a){const o=this,l=o.__v_raw,u=pn(l),c=t?$E:e?ZE:Xu;return!e&&ri(u,"iterate",ks),l.forEach((d,S)=>r.call(a,c(d),c(S),o))}}function td(e,t,n){return function(...r){const a=this.__v_raw,o=pn(a),l=Rl(o),u=e==="entries"||e===Symbol.iterator&&l,c=e==="keys"&&l,d=a[e](...r),S=n?$E:t?ZE:Xu;return!t&&ri(o,"iterate",c?kh:ks),{next(){const{value:_,done:E}=d.next();return E?{value:_,done:E}:{value:u?[S(_[0]),S(_[1])]:S(_),done:E}},[Symbol.iterator](){return this}}}}function Yo(e){return function(...t){return e==="delete"?!1:this}}function LU(){const e={get(o){return Xc(this,o)},get size(){return Jc(this)},has:Zc,add:mC,set:gC,delete:hC,clear:EC,forEach:ed(!1,!1)},t={get(o){return Xc(this,o,!1,!0)},get size(){return Jc(this)},has:Zc,add:mC,set:gC,delete:hC,clear:EC,forEach:ed(!1,!0)},n={get(o){return Xc(this,o,!0)},get size(){return Jc(this,!0)},has(o){return Zc.call(this,o,!0)},add:Yo("add"),set:Yo("set"),delete:Yo("delete"),clear:Yo("clear"),forEach:ed(!0,!1)},r={get(o){return Xc(this,o,!0,!0)},get size(){return Jc(this,!0)},has(o){return Zc.call(this,o,!0)},add:Yo("add"),set:Yo("set"),delete:Yo("delete"),clear:Yo("clear"),forEach:ed(!0,!0)};return["keys","values","entries",Symbol.iterator].forEach(o=>{e[o]=td(o,!1,!1),n[o]=td(o,!0,!1),t[o]=td(o,!1,!0),r[o]=td(o,!0,!0)}),[e,n,t,r]}const[MU,kU,PU,FU]=LU();function Sf(e,t){const n=t?e?FU:PU:e?kU:MU;return(r,a,o)=>a==="__v_isReactive"?!e:a==="__v_isReadonly"?e:a==="__v_raw"?r:Reflect.get(_n(n,a)&&a in r?n:r,a,o)}const BU={get:Sf(!1,!1)},UU={get:Sf(!1,!0)},GU={get:Sf(!0,!1)},HU={get:Sf(!0,!0)},wR=new WeakMap,LR=new WeakMap,MR=new WeakMap,kR=new WeakMap;function qU(e){switch(e){case"Object":case"Array":return 1;case"Map":case"Set":case"WeakMap":case"WeakSet":return 2;default:return 0}}function YU(e){return e.__v_skip||!Object.isExtensible(e)?0:qU(sU(e))}function ls(e){return $s(e)?e:bf(e,!1,IU,BU,wR)}function PR(e){return bf(e,!1,xU,UU,LR)}function QE(e){return bf(e,!0,DU,GU,MR)}function WU(e){return bf(e,!0,wU,HU,kR)}function bf(e,t,n,r,a){if(!ln(e)||e.__v_raw&&!(t&&e.__v_isReactive))return e;const o=a.get(e);if(o)return o;const l=YU(e);if(l===0)return e;const u=new Proxy(e,l===2?r:n);return a.set(e,u),u}function So(e){return $s(e)?So(e.__v_raw):!!(e&&e.__v_isReactive)}function $s(e){return!!(e&&e.__v_isReadonly)}function ju(e){return!!(e&&e.__v_isShallow)}function jE(e){return So(e)||$s(e)}function pn(e){const t=e&&e.__v_raw;return t?pn(t):e}function XE(e){return Ad(e,"__v_skip",!0),e}const Xu=e=>ln(e)?ls(e):e,ZE=e=>ln(e)?QE(e):e;function JE(e){es&&Sa&&(e=pn(e),RR(e.dep||(e.dep=KE())))}function vf(e,t){e=pn(e);const n=e.dep;n&&Ph(n)}function sr(e){return!!(e&&e.__v_isRef===!0)}function Dl(e){return FR(e,!1)}function VU(e){return FR(e,!0)}function FR(e,t){return sr(e)?e:new zU(e,t)}class zU{constructor(t,n){this.__v_isShallow=n,this.dep=void 0,this.__v_isRef=!0,this._rawValue=n?t:pn(t),this._value=n?t:Xu(t)}get value(){return JE(this),this._value}set value(t){const n=this.__v_isShallow||ju(t)||$s(t);t=n?t:pn(t),os(t,this._rawValue)&&(this._rawValue=t,this._value=n?t:Xu(t),vf(this))}}function KU(e){vf(e)}function eS(e){return sr(e)?e.value:e}function $U(e){return Ft(e)?e():eS(e)}const QU={get:(e,t,n)=>eS(Reflect.get(e,t,n)),set:(e,t,n,r)=>{const a=e[t];return sr(a)&&!sr(n)?(a.value=n,!0):Reflect.set(e,t,n,r)}};function tS(e){return So(e)?e:new Proxy(e,QU)}class jU{constructor(t){this.dep=void 0,this.__v_isRef=!0;const{get:n,set:r}=t(()=>JE(this),()=>vf(this));this._get=n,this._set=r}get value(){return this._get()}set value(t){this._set(t)}}function XU(e){return new jU(e)}function ZU(e){const t=Rt(e)?new Array(e.length):{};for(const n in e)t[n]=BR(e,n);return t}class JU{constructor(t,n,r){this._object=t,this._key=n,this._defaultValue=r,this.__v_isRef=!0}get value(){const t=this._object[this._key];return t===void 0?this._defaultValue:t}set value(t){this._object[this._key]=t}get dep(){return AU(pn(this._object),this._key)}}class e3{constructor(t){this._getter=t,this.__v_isRef=!0,this.__v_isReadonly=!0}get value(){return this._getter()}}function t3(e,t,n){return sr(e)?e:Ft(e)?new e3(e):ln(e)&&arguments.length>1?BR(e,t,n):Dl(e)}function BR(e,t,n){const r=e[t];return sr(r)?r:new JU(e,t,n)}class n3{constructor(t,n,r,a){this._setter=n,this.dep=void 0,this.__v_isRef=!0,this.__v_isReadonly=!1,this._dirty=!0,this.effect=new Gl(t,()=>{this._dirty||(this._dirty=!0,vf(this))}),this.effect.computed=this,this.effect.active=this._cacheable=!a,this.__v_isReadonly=r}get value(){const t=pn(this);return JE(t),(t._dirty||!t._cacheable)&&(t._dirty=!1,t._value=t.effect.run()),t._value}set value(t){this._setter(t)}}function r3(e,t,n=!1){let r,a;const o=Ft(e);return o?(r=e,a=vi):(r=e.get,a=e.set),new n3(r,a,o||!a,n)}function i3(e,...t){}function a3(e,t){}function Ya(e,t,n,r){let a;try{a=r?e(...r):e()}catch(o){el(o,t,n)}return a}function Ti(e,t,n,r){if(Ft(e)){const o=Ya(e,t,n,r);return o&&gf(o)&&o.catch(l=>{el(l,t,n)}),o}const a=[];for(let o=0;o<e.length;o++)a.push(Ti(e[o],t,n,r));return a}function el(e,t,n,r=!0){const a=t?t.vnode:null;if(t){let o=t.parent;const l=t.proxy,u=n;for(;o;){const d=o.ec;if(d){for(let S=0;S<d.length;S++)if(d[S](e,l,u)===!1)return}o=o.parent}const c=t.appContext.config.errorHandler;if(c){Ya(c,null,10,[e,l,u]);return}}o3(e,n,a,r)}function o3(e,t,n,r=!0){console.error(e)}let Zu=!1,Fh=!1;const kr=[];let Ua=0;const xl=[];let ho=null,As=0;const UR=Promise.resolve();let nS=null;function Ec(e){const t=nS||UR;return e?t.then(this?e.bind(this):e):t}function s3(e){let t=Ua+1,n=kr.length;for(;t<n;){const r=t+n>>>1,a=kr[r],o=Ju(a);o<e||o===e&&a.pre?t=r+1:n=r}return t}function Tf(e){(!kr.length||!kr.includes(e,Zu&&e.allowRecurse?Ua+1:Ua))&&(e.id==null?kr.push(e):kr.splice(s3(e.id),0,e),GR())}function GR(){!Zu&&!Fh&&(Fh=!0,nS=UR.then(HR))}function l3(e){const t=kr.indexOf(e);t>Ua&&kr.splice(t,1)}function Id(e){Rt(e)?xl.push(...e):(!ho||!ho.includes(e,e.allowRecurse?As+1:As))&&xl.push(e),GR()}function SC(e,t=Zu?Ua+1:0){for(;t<kr.length;t++){const n=kr[t];n&&n.pre&&(kr.splice(t,1),t--,n())}}function Dd(e){if(xl.length){const t=[...new Set(xl)];if(xl.length=0,ho){ho.push(...t);return}for(ho=t,ho.sort((n,r)=>Ju(n)-Ju(r)),As=0;As<ho.length;As++)ho[As]();ho=null,As=0}}const Ju=e=>e.id==null?1/0:e.id,u3=(e,t)=>{const n=Ju(e)-Ju(t);if(n===0){if(e.pre&&!t.pre)return-1;if(t.pre&&!e.pre)return 1}return n};function HR(e){Fh=!1,Zu=!0,kr.sort(u3);const t=vi;try{for(Ua=0;Ua<kr.length;Ua++){const n=kr[Ua];n&&n.active!==!1&&Ya(n,null,14)}}finally{Ua=0,kr.length=0,Dd(),Zu=!1,nS=null,(kr.length||xl.length)&&HR()}}let yl,nd=[];function qR(e,t){var n,r;yl=e,yl?(yl.enabled=!0,nd.forEach(({event:a,args:o})=>yl.emit(a,...o)),nd=[]):typeof window<"u"&&window.HTMLElement&&!((r=(n=window.navigator)==null?void 0:n.userAgent)!=null&&r.includes("jsdom"))?((t.__VUE_DEVTOOLS_HOOK_REPLAY__=t.__VUE_DEVTOOLS_HOOK_REPLAY__||[]).push(o=>{qR(o,t)}),setTimeout(()=>{yl||(t.__VUE_DEVTOOLS_HOOK_REPLAY__=null,nd=[])},3e3)):nd=[]}function c3(e,t,...n){}const rS={MODE:2};function d3(e){sn(rS,e)}function bC(e,t){const n=t&&t.type.compatConfig;return n&&e in n?n[e]:rS[e]}function Sn(e,t,n=!1){if(!n&&t&&t.type.__isBuiltIn)return!1;const r=bC("MODE",t)||2,a=bC(e,t);return(Ft(r)?r(t&&t.type):r)===2?a!==!1:a===!0||a==="suppress-warning"}function Ir(e,t,...n){if(!Sn(e,t))throw new Error(`${e} compat has been disabled.`)}function yo(e,t,...n){return Sn(e,t)}function yf(e,t,...n){return Sn(e,t)}const Bh=new WeakMap;function iS(e){let t=Bh.get(e);return t||Bh.set(e,t=Object.create(null)),t}function aS(e,t,n){if(Rt(t))t.forEach(r=>aS(e,r,n));else{t.startsWith("hook:")?Ir("INSTANCE_EVENT_HOOKS",e,t):Ir("INSTANCE_EVENT_EMITTER",e);const r=iS(e);(r[t]||(r[t]=[])).push(n)}return e.proxy}function f3(e,t,n){const r=(...a)=>{oS(e,t,r),n.call(e.proxy,...a)};return r.fn=n,aS(e,t,r),e.proxy}function oS(e,t,n){Ir("INSTANCE_EVENT_EMITTER",e);const r=e.proxy;if(!t)return Bh.set(e,Object.create(null)),r;if(Rt(t))return t.forEach(l=>oS(e,l,n)),r;const a=iS(e),o=a[t];return o?n?(a[t]=o.filter(l=>!(l===n||l.fn===n)),r):(a[t]=void 0,r):r}function p3(e,t,n){const r=iS(e)[t];return r&&Ti(r.map(a=>a.bind(e.proxy)),e,6,n),e.proxy}const Cf="onModelCompat:";function _3(e){const{type:t,shapeFlag:n,props:r,dynamicProps:a}=e,o=t;if(n&6&&r&&"modelValue"in r){if(!Sn("COMPONENT_V_MODEL",{type:t}))return;const l=o.model||{};YR(l,o.mixins);const{prop:u="value",event:c="input"}=l;u!=="modelValue"&&(r[u]=r.modelValue,delete r.modelValue),a&&(a[a.indexOf("modelValue")]=u),r[Cf+c]=r["onUpdate:modelValue"],delete r["onUpdate:modelValue"]}}function YR(e,t){t&&t.forEach(n=>{n.model&&sn(e,n.model),n.mixins&&YR(e,n.mixins)})}function m3(e,t,n){if(!Sn("COMPONENT_V_MODEL",e))return;const r=e.vnode.props,a=r&&r[Cf+t];a&&Ya(a,e,6,n)}function g3(e,t,...n){if(e.isUnmounted)return;const r=e.vnode.props||yn;let a=n;const o=t.startsWith("update:"),l=o&&t.slice(7);if(l&&l in r){const S=`${l==="modelValue"?"model":l}Modifiers`,{number:_,trim:E}=r[S]||yn;E&&(a=n.map(T=>xn(T)?T.trim():T)),_&&(a=n.map(Qu))}let u,c=r[u=Il(t)]||r[u=Il(ni(t))];!c&&o&&(c=r[u=Il(ei(t))]),c&&Ti(c,e,6,a);const d=r[u+"Once"];if(d){if(!e.emitted)e.emitted={};else if(e.emitted[u])return;e.emitted[u]=!0,Ti(d,e,6,a)}return m3(e,t,a),p3(e,t,a)}function WR(e,t,n=!1){const r=t.emitsCache,a=r.get(e);if(a!==void 0)return a;const o=e.emits;let l={},u=!1;if(!Ft(e)){const c=d=>{const S=WR(d,t,!0);S&&(u=!0,sn(l,S))};!n&&t.mixins.length&&t.mixins.forEach(c),e.extends&&c(e.extends),e.mixins&&e.mixins.forEach(c)}return!o&&!u?(ln(e)&&r.set(e,null),null):(Rt(o)?o.forEach(c=>l[c]=null):sn(l,o),ln(e)&&r.set(e,l),l)}function Af(e,t){return!e||!Co(t)?!1:t.startsWith(Cf)?!0:(t=t.slice(2).replace(/Once$/,""),_n(e,t[0].toLowerCase()+t.slice(1))||_n(e,ei(t))||_n(e,t))}let Yn=null,wl=null;function ec(e){const t=Yn;return Yn=e,wl=e&&e.type.__scopeId||null,wl||(wl=e&&e.type._scopeId||null),t}function h3(e){wl=e}function E3(){wl=null}const S3=e=>sS;function sS(e,t=Yn,n){if(!t||e._n)return e;const r=(...a)=>{r._d&&Vh(-1);const o=ec(t);let l;try{l=e(...a)}finally{ec(o),r._d&&Vh(1)}return l};return r._n=!0,r._c=!0,r._d=!0,n&&(r._ns=!0),r}function pd(e){const{type:t,vnode:n,proxy:r,withProxy:a,props:o,propsOptions:[l],slots:u,attrs:c,emit:d,render:S,renderCache:_,data:E,setupState:T,ctx:y,inheritAttrs:M}=e;let v,A;const O=ec(e);try{if(n.shapeFlag&4){const R=a||r;v=Pi(S.call(R,R,_,o,T,E,y)),A=c}else{const R=t;v=Pi(R.length>1?R(o,{attrs:c,slots:u,emit:d}):R(o,null)),A=t.props?c:v3(c)}}catch(R){Fu.length=0,el(R,e,1),v=En(Dr)}let N=v;if(A&&M!==!1){const R=Object.keys(A),{shapeFlag:L}=N;R.length&&L&7&&(l&&R.some(YE)&&(A=T3(A,l)),N=va(N,A))}if(Sn("INSTANCE_ATTRS_CLASS_STYLE",e)&&n.shapeFlag&4&&N.shapeFlag&7){const{class:R,style:L}=n.props||{};(R||L)&&(N=va(N,{class:R,style:L}))}return n.dirs&&(N=va(N),N.dirs=N.dirs?N.dirs.concat(n.dirs):n.dirs),n.transition&&(N.transition=n.transition),v=N,ec(O),v}function b3(e){let t;for(let n=0;n<e.length;n++){const r=e[n];if(Bi(r)){if(r.type!==Dr||r.children==="v-if"){if(t)return;t=r}}else return}return t}const v3=e=>{let t;for(const n in e)(n==="class"||n==="style"||Co(n))&&((t||(t={}))[n]=e[n]);return t},T3=(e,t)=>{const n={};for(const r in e)(!YE(r)||!(r.slice(9)in t))&&(n[r]=e[r]);return n};function y3(e,t,n){const{props:r,children:a,component:o}=e,{props:l,children:u,patchFlag:c}=t,d=o.emitsOptions;if(t.dirs||t.transition)return!0;if(n&&c>=0){if(c&1024)return!0;if(c&16)return r?vC(r,l,d):!!l;if(c&8){const S=t.dynamicProps;for(let _=0;_<S.length;_++){const E=S[_];if(l[E]!==r[E]&&!Af(d,E))return!0}}}else return(a||u)&&(!u||!u.$stable)?!0:r===l?!1:r?l?vC(r,l,d):!0:!!l;return!1}function vC(e,t,n){const r=Object.keys(t);if(r.length!==Object.keys(e).length)return!0;for(let a=0;a<r.length;a++){const o=r[a];if(t[o]!==e[o]&&!Af(n,o))return!0}return!1}function lS({vnode:e,parent:t},n){for(;t&&t.subTree===e;)(e=t.vnode).el=n,t=t.parent}const uS="components",C3="directives",A3="filters";function O3(e,t){return Of(uS,e,!0,t)||e}const VR=Symbol.for("v-ndc");function zR(e){return xn(e)?Of(uS,e,!1)||e:e||VR}function KR(e){return Of(C3,e)}function $R(e){return Of(A3,e)}function Of(e,t,n=!0,r=!1){const a=Yn||Xn;if(a){const o=a.type;if(e===uS){const u=Qh(o,!1);if(u&&(u===t||u===ni(t)||u===gc(ni(t))))return o}const l=TC(a[e]||o[e],t)||TC(a.appContext[e],t);return!l&&r?o:l}}function TC(e,t){return e&&(e[t]||e[ni(t)]||e[gc(ni(t))])}const QR=e=>e.__isSuspense,R3={name:"Suspense",__isSuspense:!0,process(e,t,n,r,a,o,l,u,c,d){e==null?I3(t,n,r,a,o,l,u,c,d):D3(e,t,n,r,a,l,u,c,d)},hydrate:x3,create:cS,normalize:w3},N3=R3;function tc(e,t){const n=e.props&&e.props[t];Ft(n)&&n()}function I3(e,t,n,r,a,o,l,u,c){const{p:d,o:{createElement:S}}=c,_=S("div"),E=e.suspense=cS(e,a,r,t,_,n,o,l,u,c);d(null,E.pendingBranch=e.ssContent,_,null,r,E,o,l),E.deps>0?(tc(e,"onPending"),tc(e,"onFallback"),d(null,e.ssFallback,t,n,r,null,o,l),Ll(E,e.ssFallback)):E.resolve(!1,!0)}function D3(e,t,n,r,a,o,l,u,{p:c,um:d,o:{createElement:S}}){const _=t.suspense=e.suspense;_.vnode=t,t.el=e.el;const E=t.ssContent,T=t.ssFallback,{activeBranch:y,pendingBranch:M,isInFallback:v,isHydrating:A}=_;if(M)_.pendingBranch=E,ba(E,M)?(c(M,E,_.hiddenContainer,null,a,_,o,l,u),_.deps<=0?_.resolve():v&&(c(y,T,n,r,a,null,o,l,u),Ll(_,T))):(_.pendingId++,A?(_.isHydrating=!1,_.activeBranch=M):d(M,a,_),_.deps=0,_.effects.length=0,_.hiddenContainer=S("div"),v?(c(null,E,_.hiddenContainer,null,a,_,o,l,u),_.deps<=0?_.resolve():(c(y,T,n,r,a,null,o,l,u),Ll(_,T))):y&&ba(E,y)?(c(y,E,n,r,a,_,o,l,u),_.resolve(!0)):(c(null,E,_.hiddenContainer,null,a,_,o,l,u),_.deps<=0&&_.resolve()));else if(y&&ba(E,y))c(y,E,n,r,a,_,o,l,u),Ll(_,E);else if(tc(t,"onPending"),_.pendingBranch=E,_.pendingId++,c(null,E,_.hiddenContainer,null,a,_,o,l,u),_.deps<=0)_.resolve();else{const{timeout:O,pendingId:N}=_;O>0?setTimeout(()=>{_.pendingId===N&&_.fallback(T)},O):O===0&&_.fallback(T)}}function cS(e,t,n,r,a,o,l,u,c,d,S=!1){const{p:_,m:E,um:T,n:y,o:{parentNode:M,remove:v}}=d;let A;const O=L3(e);O&&t!=null&&t.pendingBranch&&(A=t.pendingId,t.deps++);const N=e.props?Od(e.props.timeout):void 0,R={vnode:e,parent:t,parentComponent:n,isSVG:l,container:r,hiddenContainer:a,anchor:o,deps:0,pendingId:0,timeout:typeof N=="number"?N:-1,activeBranch:null,pendingBranch:null,isInFallback:!0,isHydrating:S,isUnmounted:!1,effects:[],resolve(L=!1,I=!1){const{vnode:h,activeBranch:k,pendingBranch:F,pendingId:z,effects:K,parentComponent:ue,container:Z}=R;let fe=!1;if(R.isHydrating)R.isHydrating=!1;else if(!L){fe=k&&F.transition&&F.transition.mode==="out-in",fe&&(k.transition.afterLeave=()=>{z===R.pendingId&&(E(F,Z,te,0),Id(K))});let{anchor:te}=R;k&&(te=y(k),T(k,ue,R,!0)),fe||E(F,Z,te,0)}Ll(R,F),R.pendingBranch=null,R.isInFallback=!1;let V=R.parent,ne=!1;for(;V;){if(V.pendingBranch){V.effects.push(...K),ne=!0;break}V=V.parent}!ne&&!fe&&Id(K),R.effects=[],O&&t&&t.pendingBranch&&A===t.pendingId&&(t.deps--,t.deps===0&&!I&&t.resolve()),tc(h,"onResolve")},fallback(L){if(!R.pendingBranch)return;const{vnode:I,activeBranch:h,parentComponent:k,container:F,isSVG:z}=R;tc(I,"onFallback");const K=y(h),ue=()=>{!R.isInFallback||(_(null,L,F,K,k,null,z,u,c),Ll(R,L))},Z=L.transition&&L.transition.mode==="out-in";Z&&(h.transition.afterLeave=ue),R.isInFallback=!0,T(h,k,null,!0),Z||ue()},move(L,I,h){R.activeBranch&&E(R.activeBranch,L,I,h),R.container=L},next(){return R.activeBranch&&y(R.activeBranch)},registerDep(L,I){const h=!!R.pendingBranch;h&&R.deps++;const k=L.vnode.el;L.asyncDep.catch(F=>{el(F,L,0)}).then(F=>{if(L.isUnmounted||R.isUnmounted||R.pendingId!==L.suspenseId)return;L.asyncResolved=!0;const{vnode:z}=L;zh(L,F,!1),k&&(z.el=k);const K=!k&&L.subTree.el;I(L,z,M(k||L.subTree.el),k?null:y(L.subTree),R,l,c),K&&v(K),lS(L,z.el),h&&--R.deps===0&&R.resolve()})},unmount(L,I){R.isUnmounted=!0,R.activeBranch&&T(R.activeBranch,n,L,I),R.pendingBranch&&T(R.pendingBranch,n,L,I)}};return R}function x3(e,t,n,r,a,o,l,u,c){const d=t.suspense=cS(t,r,n,e.parentNode,document.createElement("div"),null,a,o,l,u,!0),S=c(e,d.pendingBranch=t.ssContent,n,d,o,l);return d.deps===0&&d.resolve(!1,!0),S}function w3(e){const{shapeFlag:t,children:n}=e,r=t&32;e.ssContent=yC(r?n.default:n),e.ssFallback=r?yC(n.fallback):En(Dr)}function yC(e){let t;if(Ft(e)){const n=Xs&&e._c;n&&(e._d=!1,ki()),e=e(),n&&(e._d=!0,t=bi,HN())}return Rt(e)&&(e=b3(e)),e=Pi(e),t&&!e.dynamicChildren&&(e.dynamicChildren=t.filter(n=>n!==e)),e}function jR(e,t){t&&t.pendingBranch?Rt(e)?t.effects.push(...e):t.effects.push(e):Id(e)}function Ll(e,t){e.activeBranch=t;const{vnode:n,parentComponent:r}=e,a=n.el=t.el;r&&r.subTree===n&&(r.vnode.el=a,lS(r,a))}function L3(e){var t;return((t=e.props)==null?void 0:t.suspensible)!=null&&e.props.suspensible!==!1}const M3={beforeMount:"bind",mounted:"inserted",updated:["update","componentUpdated"],unmounted:"unbind"};function k3(e,t,n){const r=M3[e];if(r)if(Rt(r)){const a=[];return r.forEach(o=>{const l=t[o];l&&(yo("CUSTOM_DIR",n,o,e),a.push(l))}),a.length?a:void 0}else return t[r]&&yo("CUSTOM_DIR",n,r,e),t[r]}function P3(e,t){return Sc(e,null,t)}function XR(e,t){return Sc(e,null,{flush:"post"})}function F3(e,t){return Sc(e,null,{flush:"sync"})}const rd={};function Ps(e,t,n){return Sc(e,t,n)}function Sc(e,t,{immediate:n,deep:r,flush:a,onTrack:o,onTrigger:l}=yn){var u;const c=yR()===((u=Xn)==null?void 0:u.scope)?Xn:null;let d,S=!1,_=!1;if(sr(e)?(d=()=>e.value,S=ju(e)):So(e)?(d=()=>e,r=!0):Rt(e)?(_=!0,S=e.some(R=>So(R)||ju(R)),d=()=>e.map(R=>{if(sr(R))return R.value;if(So(R))return Zo(R);if(Ft(R))return Ya(R,c,2)})):Ft(e)?t?d=()=>Ya(e,c,2):d=()=>{if(!(c&&c.isUnmounted))return E&&E(),Ti(e,c,3,[T])}:d=vi,t&&!r){const R=d;d=()=>{const L=R();return Rt(L)&&yf("WATCH_ARRAY",c)&&Zo(L),L}}if(t&&r){const R=d;d=()=>Zo(R())}let E,T=R=>{E=O.onStop=()=>{Ya(R,c,4)}},y;if(Yl)if(T=vi,t?n&&Ti(t,c,3,[d(),_?[]:void 0,T]):d(),a==="sync"){const R=jN();y=R.__watcherHandles||(R.__watcherHandles=[])}else return vi;let M=_?new Array(e.length).fill(rd):rd;const v=()=>{if(!!O.active)if(t){const R=O.run();(r||S||(_?R.some((L,I)=>os(L,M[I])):os(R,M))||Rt(R)&&Sn("WATCH_ARRAY",c))&&(E&&E(),Ti(t,c,3,[R,M===rd?void 0:_&&M[0]===rd?[]:M,T]),M=R)}else O.run()};v.allowRecurse=!!t;let A;a==="sync"?A=v:a==="post"?A=()=>$n(v,c&&c.suspense):(v.pre=!0,c&&(v.id=c.uid),A=()=>Tf(v));const O=new Gl(d,A);t?n?v():M=O.run():a==="post"?$n(O.run.bind(O),c&&c.suspense):O.run();const N=()=>{O.stop(),c&&c.scope&&WE(c.scope.effects,O)};return y&&y.push(N),N}function B3(e,t,n){const r=this.proxy,a=xn(e)?e.includes(".")?ZR(r,e):()=>r[e]:e.bind(r,r);let o;Ft(t)?o=t:(o=t.handler,n=t);const l=Xn;us(this);const u=Sc(a,o.bind(r),n);return l?us(l):ts(),u}function ZR(e,t){const n=t.split(".");return()=>{let r=e;for(let a=0;a<n.length&&r;a++)r=r[n[a]];return r}}function Zo(e,t){if(!ln(e)||e.__v_skip||(t=t||new Set,t.has(e)))return e;if(t.add(e),sr(e))Zo(e.value,t);else if(Rt(e))for(let n=0;n<e.length;n++)Zo(e[n],t);else if(Js(e)||Rl(e))e.forEach(n=>{Zo(n,t)});else if(Cd(e))for(const n in e)Zo(e[n],t);return e}function JR(e,t){const n=Yn;if(n===null)return e;const r=Lf(n)||n.proxy,a=e.dirs||(e.dirs=[]);for(let o=0;o<t.length;o++){let[l,u,c,d=yn]=t[o];l&&(Ft(l)&&(l={mounted:l,updated:l}),l.deep&&Zo(u),a.push({dir:l,instance:r,value:u,oldValue:void 0,arg:c,modifiers:d}))}return e}function Ba(e,t,n,r){const a=e.dirs,o=t&&t.dirs;for(let l=0;l<a.length;l++){const u=a[l];o&&(u.oldValue=o[l].value);let c=u.dir[r];c||(c=k3(r,u.dir,n)),c&&(nu(),Ti(c,n,8,[e.el,u,e,t]),ru())}}const Ko=Symbol("_leaveCb"),id=Symbol("_enterCb");function dS(){const e={isMounted:!1,isLeaving:!1,isUnmounting:!1,leavingVNodes:new Map};return vc(()=>{e.isMounted=!0}),nc(()=>{e.isUnmounting=!0}),e}const ta=[Function,Array],fS={mode:String,appear:Boolean,persisted:Boolean,onBeforeEnter:ta,onEnter:ta,onAfterEnter:ta,onEnterCancelled:ta,onBeforeLeave:ta,onLeave:ta,onAfterLeave:ta,onLeaveCancelled:ta,onBeforeAppear:ta,onAppear:ta,onAfterAppear:ta,onAppearCancelled:ta},eN={name:"BaseTransition",props:fS,setup(e,{slots:t}){const n=Aa(),r=dS();let a;return()=>{const o=t.default&&Rf(t.default(),!0);if(!o||!o.length)return;let l=o[0];if(o.length>1){for(const M of o)if(M.type!==Dr){l=M;break}}const u=pn(e),{mode:c}=u;if(r.isLeaving)return Jg(l);const d=CC(l);if(!d)return Jg(l);const S=Hl(d,u,r,n);Qs(d,S);const _=n.subTree,E=_&&CC(_);let T=!1;const{getTransitionKey:y}=d.type;if(y){const M=y();a===void 0?a=M:M!==a&&(a=M,T=!0)}if(E&&E.type!==Dr&&(!ba(d,E)||T)){const M=Hl(E,u,r,n);if(Qs(E,M),c==="out-in")return r.isLeaving=!0,M.afterLeave=()=>{r.isLeaving=!1,n.update.active!==!1&&n.update()},Jg(l);c==="in-out"&&d.type!==Dr&&(M.delayLeave=(v,A,O)=>{const N=nN(r,E);N[String(E.key)]=E,v[Ko]=()=>{A(),v[Ko]=void 0,delete S.delayedLeave},S.delayedLeave=O})}return l}}};eN.__isBuiltIn=!0;const tN=eN;function nN(e,t){const{leavingVNodes:n}=e;let r=n.get(t.type);return r||(r=Object.create(null),n.set(t.type,r)),r}function Hl(e,t,n,r){const{appear:a,mode:o,persisted:l=!1,onBeforeEnter:u,onEnter:c,onAfterEnter:d,onEnterCancelled:S,onBeforeLeave:_,onLeave:E,onAfterLeave:T,onLeaveCancelled:y,onBeforeAppear:M,onAppear:v,onAfterAppear:A,onAppearCancelled:O}=t,N=String(e.key),R=nN(n,e),L=(k,F)=>{k&&Ti(k,r,9,F)},I=(k,F)=>{const z=F[1];L(k,F),Rt(k)?k.every(K=>K.length<=1)&&z():k.length<=1&&z()},h={mode:o,persisted:l,beforeEnter(k){let F=u;if(!n.isMounted)if(a)F=M||u;else return;k[Ko]&&k[Ko](!0);const z=R[N];z&&ba(e,z)&&z.el[Ko]&&z.el[Ko](),L(F,[k])},enter(k){let F=c,z=d,K=S;if(!n.isMounted)if(a)F=v||c,z=A||d,K=O||S;else return;let ue=!1;const Z=k[id]=fe=>{ue||(ue=!0,fe?L(K,[k]):L(z,[k]),h.delayedLeave&&h.delayedLeave(),k[id]=void 0)};F?I(F,[k,Z]):Z()},leave(k,F){const z=String(e.key);if(k[id]&&k[id](!0),n.isUnmounting)return F();L(_,[k]);let K=!1;const ue=k[Ko]=Z=>{K||(K=!0,F(),Z?L(y,[k]):L(T,[k]),k[Ko]=void 0,R[z]===e&&delete R[z])};R[z]=e,E?I(E,[k,ue]):ue()},clone(k){return Hl(k,t,n,r)}};return h}function Jg(e){if(bc(e))return e=va(e),e.children=null,e}function CC(e){return bc(e)?e.children?e.children[0]:void 0:e}function Qs(e,t){e.shapeFlag&6&&e.component?Qs(e.component.subTree,t):e.shapeFlag&128?(e.ssContent.transition=t.clone(e.ssContent),e.ssFallback.transition=t.clone(e.ssFallback)):e.transition=t}function Rf(e,t=!1,n){let r=[],a=0;for(let o=0;o<e.length;o++){let l=e[o];const u=n==null?l.key:String(n)+String(l.key!=null?l.key:o);l.type===hr?(l.patchFlag&128&&a++,r=r.concat(Rf(l.children,t,u))):(t||l.type!==Dr)&&r.push(u!=null?va(l,{key:u}):l)}if(a>1)for(let o=0;o<r.length;o++)r[o].patchFlag=-2;return r}/*! #__NO_SIDE_EFFECTS__ */function pS(e,t){return Ft(e)?(()=>sn({name:e.name},t,{setup:e}))():e}const Fs=e=>!!e.type.__asyncLoader;/*! #__NO_SIDE_EFFECTS__ */function _d(e){Ft(e)&&(e={loader:e});const{loader:t,loadingComponent:n,errorComponent:r,delay:a=200,timeout:o,suspensible:l=!0,onError:u}=e;let c=null,d,S=0;const _=()=>(S++,c=null,E()),E=()=>{let T;return c||(T=c=t().catch(y=>{if(y=y instanceof Error?y:new Error(String(y)),u)return new Promise((M,v)=>{u(y,()=>M(_()),()=>v(y),S+1)});throw y}).then(y=>T!==c&&c?c:(y&&(y.__esModule||y[Symbol.toStringTag]==="Module")&&(y=y.default),d=y,y)))};return pS({name:"AsyncComponentWrapper",__asyncLoader:E,get __asyncResolved(){return d},setup(){const T=Xn;if(d)return()=>eh(d,T);const y=O=>{c=null,el(O,T,13,!r)};if(l&&T.suspense||Yl)return E().then(O=>()=>eh(O,T)).catch(O=>(y(O),()=>r?En(r,{error:O}):null));const M=Dl(!1),v=Dl(),A=Dl(!!a);return a&&setTimeout(()=>{A.value=!1},a),o!=null&&setTimeout(()=>{if(!M.value&&!v.value){const O=new Error(`Async component timed out after ${o}ms.`);y(O),v.value=O}},o),E().then(()=>{M.value=!0,T.parent&&bc(T.parent.vnode)&&Tf(T.parent.update)}).catch(O=>{y(O),v.value=O}),()=>{if(M.value&&d)return eh(d,T);if(v.value&&r)return En(r,{error:v.value});if(n&&!A.value)return En(n)}}})}function eh(e,t){const{ref:n,props:r,children:a,ce:o}=t.vnode,l=En(e,r,a);return l.ref=n,l.ce=o,delete t.vnode.ce,l}const bc=e=>e.type.__isKeepAlive,rN={name:"KeepAlive",__isKeepAlive:!0,props:{include:[String,RegExp,Array],exclude:[String,RegExp,Array],max:[String,Number]},setup(e,{slots:t}){const n=Aa(),r=n.ctx;if(!r.renderer)return()=>{const O=t.default&&t.default();return O&&O.length===1?O[0]:O};const a=new Map,o=new Set;let l=null;const u=n.suspense,{renderer:{p:c,m:d,um:S,o:{createElement:_}}}=r,E=_("div");r.activate=(O,N,R,L,I)=>{const h=O.component;d(O,N,R,0,u),c(h.vnode,O,N,R,h,u,L,O.slotScopeIds,I),$n(()=>{h.isDeactivated=!1,h.a&&Jo(h.a);const k=O.props&&O.props.onVnodeMounted;k&&Ei(k,h.parent,O)},u)},r.deactivate=O=>{const N=O.component;d(O,E,null,1,u),$n(()=>{N.da&&Jo(N.da);const R=O.props&&O.props.onVnodeUnmounted;R&&Ei(R,N.parent,O),N.isDeactivated=!0},u)};function T(O){th(O),S(O,n,u,!0)}function y(O){a.forEach((N,R)=>{const L=Qh(N.type);L&&(!O||!O(L))&&M(R)})}function M(O){const N=a.get(O);!l||!ba(N,l)?T(N):l&&th(l),a.delete(O),o.delete(O)}Ps(()=>[e.include,e.exclude],([O,N])=>{O&&y(R=>xu(O,R)),N&&y(R=>!xu(N,R))},{flush:"post",deep:!0});let v=null;const A=()=>{v!=null&&a.set(v,nh(n.subTree))};return vc(A),If(A),nc(()=>{a.forEach(O=>{const{subTree:N,suspense:R}=n,L=nh(N);if(O.type===L.type&&O.key===L.key){th(L);const I=L.component.da;I&&$n(I,R);return}T(O)})}),()=>{if(v=null,!t.default)return null;const O=t.default(),N=O[0];if(O.length>1)return l=null,O;if(!Bi(N)||!(N.shapeFlag&4)&&!(N.shapeFlag&128))return l=null,N;let R=nh(N);const L=R.type,I=Qh(Fs(R)?R.type.__asyncResolved||{}:L),{include:h,exclude:k,max:F}=e;if(h&&(!I||!xu(h,I))||k&&I&&xu(k,I))return l=R,N;const z=R.key==null?L:R.key,K=a.get(z);return R.el&&(R=va(R),N.shapeFlag&128&&(N.ssContent=R)),v=z,K?(R.el=K.el,R.component=K.component,R.transition&&Qs(R,R.transition),R.shapeFlag|=512,o.delete(z),o.add(z)):(o.add(z),F&&o.size>parseInt(F,10)&&M(o.values().next().value)),R.shapeFlag|=256,l=R,QR(N.type)?N:R}}};rN.__isBuildIn=!0;const iN=rN;function xu(e,t){return Rt(e)?e.some(n=>xu(n,t)):xn(e)?e.split(",").includes(t):oU(e)?e.test(t):!1}function aN(e,t){sN(e,"a",t)}function oN(e,t){sN(e,"da",t)}function sN(e,t,n=Xn){const r=e.__wdc||(e.__wdc=()=>{let a=n;for(;a;){if(a.isDeactivated)return;a=a.parent}return e()});if(Nf(t,r,n),n){let a=n.parent;for(;a&&a.parent;)bc(a.parent.vnode)&&U3(r,t,n,a),a=a.parent}}function U3(e,t,n,r){const a=Nf(t,e,r,!0);rc(()=>{WE(r[t],a)},n)}function th(e){e.shapeFlag&=-257,e.shapeFlag&=-513}function nh(e){return e.shapeFlag&128?e.ssContent:e}function Nf(e,t,n=Xn,r=!1){if(n){const a=n[e]||(n[e]=[]),o=t.__weh||(t.__weh=(...l)=>{if(n.isUnmounted)return;nu(),us(n);const u=Ti(t,n,e,l);return ts(),ru(),u});return r?a.unshift(o):a.push(o),o}}const Ao=e=>(t,n=Xn)=>(!Yl||e==="sp")&&Nf(e,(...r)=>t(...r),n),lN=Ao("bm"),vc=Ao("m"),uN=Ao("bu"),If=Ao("u"),nc=Ao("bum"),rc=Ao("um"),cN=Ao("sp"),dN=Ao("rtg"),fN=Ao("rtc");function pN(e,t=Xn){Nf("ec",e,t)}function G3(e){Ir("INSTANCE_CHILDREN",e);const t=e.subTree,n=[];return t&&_N(t,n),n}function _N(e,t){if(e.component)t.push(e.component.proxy);else if(e.shapeFlag&16){const n=e.children;for(let r=0;r<n.length;r++)_N(n[r],t)}}function mN(e){Ir("INSTANCE_LISTENERS",e);const t={},n=e.vnode.props;if(!n)return t;for(const r in n)Co(r)&&(t[r[2].toLowerCase()+r.slice(3)]=n[r]);return t}function H3(e){const t=e.type,n=t.render;if(!(!n||n._rc||n._compatChecked||n._compatWrapped)){if(n.length>=2){n._compatChecked=!0;return}if(yf("RENDER_FUNCTION",e)){const r=t.render=function(){return n.call(this,xd)};r._compatWrapped=!0}}}function xd(e,t,n){if(e||(e=Dr),typeof e=="string"){const o=ei(e);(o==="transition"||o==="transition-group"||o==="keep-alive")&&(e=`__compat__${o}`),e=zR(e)}const r=arguments.length,a=Rt(t);return r===2||a?ln(t)&&!a?Bi(t)?ad(En(e,null,[t])):ad(OC(En(e,AC(t,e)),t)):ad(En(e,null,t)):(Bi(n)&&(n=[n]),ad(OC(En(e,AC(t,e),n),t)))}const q3=Jl("staticStyle,staticClass,directives,model,hook");function AC(e,t){if(!e)return null;const n={};for(const r in e)if(r==="attrs"||r==="domProps"||r==="props")sn(n,e[r]);else if(r==="on"||r==="nativeOn"){const a=e[r];for(const o in a){let l=Y3(o);r==="nativeOn"&&(l+="Native");const u=n[l],c=a[o];u!==c&&(u?n[l]=[].concat(u,c):n[l]=c)}}else q3(r)||(n[r]=e[r]);if(e.staticClass&&(n.class=Va([e.staticClass,n.class])),e.staticStyle&&(n.style=tu([e.staticStyle,n.style])),e.model&&ln(t)){const{prop:r="value",event:a="input"}=t.model||{};n[r]=e.model.value,n[Cf+a]=e.model.callback}return n}function Y3(e){return e[0]==="&"&&(e=e.slice(1)+"Passive"),e[0]==="~"&&(e=e.slice(1)+"Once"),e[0]==="!"&&(e=e.slice(1)+"Capture"),Il(e)}function OC(e,t){return t&&t.directives?JR(e,t.directives.map(({name:n,value:r,arg:a,modifiers:o})=>[KR(n),r,a,o])):e}function ad(e){const{props:t,children:n}=e;let r;if(e.shapeFlag&6&&Rt(n)){r={};for(let o=0;o<n.length;o++){const l=n[o],u=Bi(l)&&l.props&&l.props.slot||"default",c=r[u]||(r[u]=[]);Bi(l)&&l.type==="template"?c.push(l.children):c.push(l)}if(r)for(const o in r){const l=r[o];r[o]=()=>l,r[o]._ns=!0}}const a=t&&t.scopedSlots;return a&&(delete t.scopedSlots,r?sn(r,a):r=a),r&&xf(e,r),e}function gN(e){if(Sn("RENDER_FUNCTION",Yn,!0)&&Sn("PRIVATE_APIS",Yn,!0)){const t=Yn,n=()=>e.component&&e.component.proxy;let r;Object.defineProperties(e,{tag:{get:()=>e.type},data:{get:()=>e.props||{},set:a=>e.props=a},elm:{get:()=>e.el},componentInstance:{get:n},child:{get:n},text:{get:()=>xn(e.children)?e.children:null},context:{get:()=>t&&t.proxy},componentOptions:{get:()=>{if(e.shapeFlag&4)return r||(r={Ctor:e.type,propsData:e.props,children:e.children})}}})}}const rh=new WeakMap,hN={get(e,t){const n=e[t];return n&&n()}};function W3(e){if(rh.has(e))return rh.get(e);const t=e.render,n=(r,a)=>{const o=Aa(),l={props:r,children:o.vnode.children||[],data:o.vnode.props||{},scopedSlots:a.slots,parent:o.parent&&o.parent.proxy,slots(){return new Proxy(a.slots,hN)},get listeners(){return mN(o)},get injections(){if(e.inject){const u={};return AN(e.inject,u),u}return{}}};return t(xd,l)};return n.props=e.props,n.displayName=e.name,n.compatConfig=e.compatConfig,n.inheritAttrs=!1,rh.set(e,n),n}function _S(e,t,n,r){let a;const o=n&&n[r];if(Rt(e)||xn(e)){a=new Array(e.length);for(let l=0,u=e.length;l<u;l++)a[l]=t(e[l],l,void 0,o&&o[l])}else if(typeof e=="number"){a=new Array(e);for(let l=0;l<e;l++)a[l]=t(l+1,l,void 0,o&&o[l])}else if(ln(e))if(e[Symbol.iterator])a=Array.from(e,(l,u)=>t(l,u,void 0,o&&o[u]));else{const l=Object.keys(e);a=new Array(l.length);for(let u=0,c=l.length;u<c;u++){const d=l[u];a[u]=t(e[d],d,u,o&&o[u])}}else a=[];return n&&(n[r]=a),a}function EN(e,t){for(let n=0;n<t.length;n++){const r=t[n];if(Rt(r))for(let a=0;a<r.length;a++)e[r[a].name]=r[a].fn;else r&&(e[r.name]=r.key?(...a)=>{const o=r.fn(...a);return o&&(o.key=r.key),o}:r.fn)}return e}function SN(e,t,n={},r,a){if(Yn.isCE||Yn.parent&&Fs(Yn.parent)&&Yn.parent.isCE)return t!=="default"&&(n.name=t),En("slot",n,r&&r());let o=e[t];o&&o._c&&(o._d=!1),ki();const l=o&&bN(o(n)),u=hS(hr,{key:n.key||l&&l.key||`_${t}`},l||(r?r():[]),l&&e._===1?64:-2);return!a&&u.scopeId&&(u.slotScopeIds=[u.scopeId+"-s"]),o&&o._c&&(o._d=!0),u}function bN(e){return e.some(t=>Bi(t)?!(t.type===Dr||t.type===hr&&!bN(t.children)):!0)?e:null}function vN(e,t){const n={};for(const r in e)n[t&&/[A-Z]/.test(r)?`on:${r}`:Il(r)]=e[r];return n}function V3(e){const t={};for(let n=0;n<e.length;n++)e[n]&&sn(t,e[n]);return t}function z3(e,t,n,r,a){if(n&&ln(n)){Rt(n)&&(n=V3(n));for(const o in n)if(Nl(o))e[o]=n[o];else if(o==="class")e.class=Va([e.class,n.class]);else if(o==="style")e.style=Va([e.style,n.style]);else{const l=e.attrs||(e.attrs={}),u=ni(o),c=ei(o);if(!(u in l)&&!(c in l)&&(l[o]=n[o],a)){const d=e.on||(e.on={});d[`update:${o}`]=function(S){n[o]=S}}}}return e}function K3(e,t){return wf(e,vN(t))}function $3(e,t,n,r,a){return a&&(r=wf(r,a)),SN(e.slots,t,r,n&&(()=>n))}function Q3(e,t,n){return EN(t||{$stable:!n},TN(e))}function TN(e){for(let t=0;t<e.length;t++){const n=e[t];n&&(Rt(n)?TN(n):n.name=n.key||"default")}return e}const RC=new WeakMap;function j3(e,t){let n=RC.get(e);if(n||RC.set(e,n=[]),n[t])return n[t];const r=e.type.staticRenderFns[t],a=e.proxy;return n[t]=r.call(a,null,a)}function X3(e,t,n,r,a,o){const u=e.appContext.config.keyCodes||{},c=u[n]||r;if(o&&a&&!u[n])return NC(o,a);if(c)return NC(c,t);if(a)return ei(a)!==n}function NC(e,t){return Rt(e)?!e.includes(t):e!==t}function Z3(e){return e}function J3(e,t){for(let n=0;n<t.length;n+=2){const r=t[n];typeof r=="string"&&r&&(e[t[n]]=t[n+1])}return e}function eG(e,t){return typeof e=="string"?t+e:e}function tG(e){const t=(r,a,o)=>(r[a]=o,r[a]),n=(r,a)=>{delete r[a]};sn(e,{$set:r=>(Ir("INSTANCE_SET",r),t),$delete:r=>(Ir("INSTANCE_DELETE",r),n),$mount:r=>(Ir("GLOBAL_MOUNT",null),r.ctx._compat_mount||vi),$destroy:r=>(Ir("INSTANCE_DESTROY",r),r.ctx._compat_destroy||vi),$slots:r=>Sn("RENDER_FUNCTION",r)&&r.render&&r.render._compatWrapped?new Proxy(r.slots,hN):r.slots,$scopedSlots:r=>{Ir("INSTANCE_SCOPED_SLOTS",r);const a={};for(const o in r.slots){const l=r.slots[o];l._ns||(a[o]=l)}return a},$on:r=>aS.bind(null,r),$once:r=>f3.bind(null,r),$off:r=>oS.bind(null,r),$children:G3,$listeners:mN}),Sn("PRIVATE_APIS",null)&&sn(e,{$vnode:r=>r.vnode,$options:r=>{const a=sn({},Tc(r));return a.parent=r.proxy.$parent,a.propsData=r.vnode.props,a},_self:r=>r.proxy,_uid:r=>r.uid,_data:r=>r.data,_isMounted:r=>r.isMounted,_isDestroyed:r=>r.isUnmounted,$createElement:()=>xd,_c:()=>xd,_o:()=>Z3,_n:()=>Qu,_s:()=>Rd,_l:()=>_S,_t:r=>$3.bind(null,r),_q:()=>To,_i:()=>hc,_m:r=>j3.bind(null,r),_f:()=>$R,_k:r=>X3.bind(null,r),_b:()=>z3,_v:()=>ql,_e:()=>Ld,_u:()=>Q3,_g:()=>K3,_d:()=>J3,_p:()=>eG})}const Uh=e=>e?VN(e)?Lf(e)||e.proxy:Uh(e.parent):null,Ml=sn(Object.create(null),{$:e=>e,$el:e=>e.vnode.el,$data:e=>e.data,$props:e=>e.props,$attrs:e=>e.attrs,$slots:e=>e.slots,$refs:e=>e.refs,$parent:e=>Uh(e.parent),$root:e=>Uh(e.root),$emit:e=>e.emit,$options:e=>Tc(e),$forceUpdate:e=>e.f||(e.f=()=>Tf(e.update)),$nextTick:e=>e.n||(e.n=Ec.bind(e.proxy)),$watch:e=>B3.bind(e)});tG(Ml);const ih=(e,t)=>e!==yn&&!e.__isScriptSetup&&_n(e,t),Gh={get({_:e},t){const{ctx:n,setupState:r,data:a,props:o,accessCache:l,type:u,appContext:c}=e;let d;if(t[0]!=="$"){const T=l[t];if(T!==void 0)switch(T){case 1:return r[t];case 2:return a[t];case 4:return n[t];case 3:return o[t]}else{if(ih(r,t))return l[t]=1,r[t];if(a!==yn&&_n(a,t))return l[t]=2,a[t];if((d=e.propsOptions[0])&&_n(d,t))return l[t]=3,o[t];if(n!==yn&&_n(n,t))return l[t]=4,n[t];Hh&&(l[t]=0)}}const S=Ml[t];let _,E;if(S)return t==="$attrs"&&ri(e,"get",t),S(e);if((_=u.__cssModules)&&(_=_[t]))return _;if(n!==yn&&_n(n,t))return l[t]=4,n[t];if(E=c.config.globalProperties,_n(E,t)){const T=Object.getOwnPropertyDescriptor(E,t);if(T.get)return T.get.call(e.proxy);{const y=E[t];return Ft(y)?Object.assign(y.bind(e.proxy),y):y}}},set({_:e},t,n){const{data:r,setupState:a,ctx:o}=e;return ih(a,t)?(a[t]=n,!0):r!==yn&&_n(r,t)?(r[t]=n,!0):_n(e.props,t)||t[0]==="$"&&t.slice(1)in e?!1:(o[t]=n,!0)},has({_:{data:e,setupState:t,accessCache:n,ctx:r,appContext:a,propsOptions:o}},l){let u;return!!n[l]||e!==yn&&_n(e,l)||ih(t,l)||(u=o[0])&&_n(u,l)||_n(r,l)||_n(Ml,l)||_n(a.config.globalProperties,l)},defineProperty(e,t,n){return n.get!=null?e._.accessCache[t]=0:_n(n,"value")&&this.set(e,t,n.value,null),Reflect.defineProperty(e,t,n)}},nG=sn({},Gh,{get(e,t){if(t!==Symbol.unscopables)return Gh.get(e,t,e)},has(e,t){return t[0]!=="_"&&!dU(t)}});function yN(e,t){for(const n in t){const r=e[n],a=t[n];n in e&&Cd(r)&&Cd(a)?yN(r,a):e[n]=a}return e}function rG(){return null}function iG(){return null}function aG(e){}function oG(e){}function sG(){return null}function lG(){}function uG(e,t){return null}function cG(){return CN().slots}function dG(){return CN().attrs}function fG(e,t,n){const r=Aa();if(n&&n.local){const a=Dl(e[t]);return Ps(()=>e[t],o=>a.value=o),Ps(a,o=>{o!==e[t]&&r.emit(`update:${t}`,o)}),a}else return{__v_isRef:!0,get value(){return e[t]},set value(a){r.emit(`update:${t}`,a)}}}function CN(){const e=Aa();return e.setupContext||(e.setupContext=zN(e))}function ic(e){return Rt(e)?e.reduce((t,n)=>(t[n]=null,t),{}):e}function pG(e,t){const n=ic(e);for(const r in t){if(r.startsWith("__skip"))continue;let a=n[r];a?Rt(a)||Ft(a)?a=n[r]={type:a,default:t[r]}:a.default=t[r]:a===null&&(a=n[r]={default:t[r]}),a&&t[`__skip_${r}`]&&(a.skipFactory=!0)}return n}function _G(e,t){return!e||!t?e||t:Rt(e)&&Rt(t)?e.concat(t):sn({},ic(e),ic(t))}function mG(e,t){const n={};for(const r in e)t.includes(r)||Object.defineProperty(n,r,{enumerable:!0,get:()=>e[r]});return n}function gG(e){const t=Aa();let n=e();return ts(),gf(n)&&(n=n.catch(r=>{throw us(t),r})),[n,()=>us(t)]}let Hh=!0;function hG(e){const t=Tc(e),n=e.proxy,r=e.ctx;Hh=!1,t.beforeCreate&&IC(t.beforeCreate,e,"bc");const{data:a,computed:o,methods:l,watch:u,provide:c,inject:d,created:S,beforeMount:_,mounted:E,beforeUpdate:T,updated:y,activated:M,deactivated:v,beforeDestroy:A,beforeUnmount:O,destroyed:N,unmounted:R,render:L,renderTracked:I,renderTriggered:h,errorCaptured:k,serverPrefetch:F,expose:z,inheritAttrs:K,components:ue,directives:Z,filters:fe}=t;if(d&&AN(d,r,null),l)for(const te in l){const G=l[te];Ft(G)&&(r[te]=G.bind(n))}if(a){const te=a.call(n,n);ln(te)&&(e.data=ls(te))}if(Hh=!0,o)for(const te in o){const G=o[te],se=Ft(G)?G.bind(n,n):Ft(G.get)?G.get.bind(n,n):vi,ve=!Ft(G)&&Ft(G.set)?G.set.bind(n):vi,Ge=KN({get:se,set:ve});Object.defineProperty(r,te,{enumerable:!0,configurable:!0,get:()=>Ge.value,set:oe=>Ge.value=oe})}if(u)for(const te in u)ON(u[te],r,n,te);if(c){const te=Ft(c)?c.call(n):c;Reflect.ownKeys(te).forEach(G=>{IN(G,te[G])})}S&&IC(S,e,"c");function ne(te,G){Rt(G)?G.forEach(se=>te(se.bind(n))):G&&te(G.bind(n))}if(ne(lN,_),ne(vc,E),ne(uN,T),ne(If,y),ne(aN,M),ne(oN,v),ne(pN,k),ne(fN,I),ne(dN,h),ne(nc,O),ne(rc,R),ne(cN,F),A&&yo("OPTIONS_BEFORE_DESTROY",e)&&ne(nc,A),N&&yo("OPTIONS_DESTROYED",e)&&ne(rc,N),Rt(z))if(z.length){const te=e.exposed||(e.exposed={});z.forEach(G=>{Object.defineProperty(te,G,{get:()=>n[G],set:se=>n[G]=se})})}else e.exposed||(e.exposed={});L&&e.render===vi&&(e.render=L),K!=null&&(e.inheritAttrs=K),ue&&(e.components=ue),Z&&(e.directives=Z),fe&&Sn("FILTERS",e)&&(e.filters=fe)}function AN(e,t,n=vi){Rt(e)&&(e=qh(e));for(const r in e){const a=e[r];let o;ln(a)?"default"in a?o=Gs(a.from||r,a.default,!0):o=Gs(a.from||r):o=Gs(a),sr(o)?Object.defineProperty(t,r,{enumerable:!0,configurable:!0,get:()=>o.value,set:l=>o.value=l}):t[r]=o}}function IC(e,t,n){Ti(Rt(e)?e.map(r=>r.bind(t.proxy)):e.bind(t.proxy),t,n)}function ON(e,t,n,r){const a=r.includes(".")?ZR(n,r):()=>n[r];if(xn(e)){const o=t[e];Ft(o)&&Ps(a,o)}else if(Ft(e))Ps(a,e.bind(n));else if(ln(e))if(Rt(e))e.forEach(o=>ON(o,t,n,r));else{const o=Ft(e.handler)?e.handler.bind(n):t[e.handler];Ft(o)&&Ps(a,o,e)}}function Tc(e){const t=e.type,{mixins:n,extends:r}=t,{mixins:a,optionsCache:o,config:{optionMergeStrategies:l}}=e.appContext,u=o.get(t);let c;return u?c=u:!a.length&&!n&&!r?Sn("PRIVATE_APIS",e)?(c=sn({},t),c.parent=e.parent&&e.parent.proxy,c.propsData=e.vnode.props):c=t:(c={},a.length&&a.forEach(d=>Bs(c,d,l,!0)),Bs(c,t,l)),ln(t)&&o.set(t,c),c}function Bs(e,t,n,r=!1){Ft(t)&&(t=t.options);const{mixins:a,extends:o}=t;o&&Bs(e,o,n,!0),a&&a.forEach(l=>Bs(e,l,n,!0));for(const l in t)if(!(r&&l==="expose")){const u=Us[l]||n&&n[l];e[l]=u?u(e[l],t[l]):t[l]}return e}const Us={data:DC,props:xC,emits:xC,methods:Cl,computed:Cl,beforeCreate:Xr,created:Xr,beforeMount:Xr,mounted:Xr,beforeUpdate:Xr,updated:Xr,beforeDestroy:Xr,beforeUnmount:Xr,destroyed:Xr,unmounted:Xr,activated:Xr,deactivated:Xr,errorCaptured:Xr,serverPrefetch:Xr,components:Cl,directives:Cl,watch:SG,provide:DC,inject:EG};Us.filters=Cl;function DC(e,t){return t?e?function(){return(Sn("OPTIONS_DATA_MERGE",null)?yN:sn)(Ft(e)?e.call(this,this):e,Ft(t)?t.call(this,this):t)}:t:e}function EG(e,t){return Cl(qh(e),qh(t))}function qh(e){if(Rt(e)){const t={};for(let n=0;n<e.length;n++)t[e[n]]=e[n];return t}return e}function Xr(e,t){return e?[...new Set([].concat(e,t))]:t}function Cl(e,t){return e?sn(Object.create(null),e,t):t}function xC(e,t){return e?Rt(e)&&Rt(t)?[...new Set([...e,...t])]:sn(Object.create(null),ic(e),ic(t!=null?t:{})):t}function SG(e,t){if(!e)return t;if(!t)return e;const n=sn(Object.create(null),e);for(const r in t)n[r]=Xr(e[r],t[r]);return n}function bG(e){e.optionMergeStrategies=new Proxy({},{get(t,n){if(n in t)return t[n];if(n in Us&&yo("CONFIG_OPTION_MERGE_STRATS",null))return Us[n]}})}let Si,Os;function vG(e,t){Si=t({});const n=Os=function c(d={}){return r(d,c)};function r(c={},d){Ir("GLOBAL_MOUNT",null);const{data:S}=c;S&&!Ft(S)&&yo("OPTIONS_DATA_FN",null)&&(c.data=()=>S);const _=e(c);d!==n&&RN(_,d);const E=_._createRoot(c);return c.el?E.$mount(c.el):E}n.version="2.6.14-compat:3.3.8",n.config=Si.config,n.use=(c,...d)=>(c&&Ft(c.install)?c.install(n,...d):Ft(c)&&c(n,...d),n),n.mixin=c=>(Si.mixin(c),n),n.component=(c,d)=>d?(Si.component(c,d),n):Si.component(c),n.directive=(c,d)=>d?(Si.directive(c,d),n):Si.directive(c),n.options={_base:n};let a=1;n.cid=a,n.nextTick=Ec;const o=new WeakMap;function l(c={}){if(Ir("GLOBAL_EXTEND",null),Ft(c)&&(c=c.options),o.has(c))return o.get(c);const d=this;function S(E){return r(E?Bs(sn({},S.options),E,Us):S.options,S)}S.super=d,S.prototype=Object.create(n.prototype),S.prototype.constructor=S;const _={};for(const E in d.options){const T=d.options[E];_[E]=Rt(T)?T.slice():ln(T)?sn(Object.create(null),T):T}return S.options=Bs(_,c,Us),S.options._base=S,S.extend=l.bind(S),S.mixin=d.mixin,S.use=d.use,S.cid=++a,o.set(c,S),S}n.extend=l.bind(n),n.set=(c,d,S)=>{Ir("GLOBAL_SET",null),c[d]=S},n.delete=(c,d)=>{Ir("GLOBAL_DELETE",null),delete c[d]},n.observable=c=>(Ir("GLOBAL_OBSERVABLE",null),ls(c)),n.filter=(c,d)=>d?(Si.filter(c,d),n):Si.filter(c);const u={warn:vi,extend:sn,mergeOptions:(c,d,S)=>Bs(c,d,S?void 0:Us),defineReactive:IG};return Object.defineProperty(n,"util",{get(){return Ir("GLOBAL_PRIVATE_UTIL",null),u}}),n.configureCompat=d3,n}function TG(e,t,n){yG(e,t),bG(e.config),Si&&(OG(e,t,n),CG(e),AG(e))}function yG(e,t){t.filters={},e.filter=(n,r)=>(Ir("FILTERS",null),r?(t.filters[n]=r,e):t.filters[n])}function CG(e){Object.defineProperties(e,{prototype:{get(){return e.config.globalProperties}},nextTick:{value:Ec},extend:{value:Os.extend},set:{value:Os.set},delete:{value:Os.delete},observable:{value:Os.observable},util:{get(){return Os.util}}})}function AG(e){e._context.mixins=[...Si._context.mixins],["components","directives","filters"].forEach(t=>{e._context[t]=Object.create(Si._context[t])});for(const t in Si.config){if(t==="isNativeTag"||$h()&&(t==="isCustomElement"||t==="compilerOptions"))continue;const n=Si.config[t];e.config[t]=ln(n)?Object.create(n):n,t==="ignoredElements"&&Sn("CONFIG_IGNORED_ELEMENTS",null)&&!$h()&&Rt(n)&&(e.config.compilerOptions.isCustomElement=r=>n.some(a=>xn(a)?a===r:a.test(r)))}RN(e,Os)}function RN(e,t){const n=Sn("GLOBAL_PROTOTYPE",null);n&&(e.config.globalProperties=Object.create(t.prototype));const r=Object.getOwnPropertyDescriptors(t.prototype);for(const a in r)a!=="constructor"&&n&&Object.defineProperty(e.config.globalProperties,a,r[a])}function OG(e,t,n){let r=!1;e._createRoot=a=>{const o=e._component,l=En(o,a.propsData||null);l.appContext=t;const u=!Ft(o)&&!o.render&&!o.template,c=()=>{},d=SS(l,null,null);return u&&(d.render=c),vS(d),l.component=d,l.isCompatRoot=!0,d.ctx._compat_mount=S=>{if(r)return;let _;if(typeof S=="string"){const T=document.querySelector(S);if(!T)return;_=T}else _=S||document.createElement("div");const E=_ instanceof SVGElement;return u&&d.render===c&&(d.render=null,o.template=_.innerHTML,TS(d,!1,!0)),_.innerHTML="",n(l,_,E),_ instanceof Element&&(_.removeAttribute("v-cloak"),_.setAttribute("data-v-app","")),r=!0,e._container=_,_.__vue_app__=e,d.proxy},d.ctx._compat_destroy=()=>{if(r)n(null,e._container),delete e._container.__vue_app__;else{const{bum:S,scope:_,um:E}=d;S&&Jo(S),Sn("INSTANCE_EVENT_HOOKS",d)&&d.emit("hook:beforeDestroy"),_&&_.stop(),E&&Jo(E),Sn("INSTANCE_EVENT_HOOKS",d)&&d.emit("hook:destroyed")}},d.proxy}}const RG=["push","pop","shift","unshift","splice","sort","reverse"],NG=new WeakSet;function IG(e,t,n){if(ln(n)&&!So(n)&&!NG.has(n)){const a=ls(n);Rt(n)?RG.forEach(o=>{n[o]=(...l)=>{Array.prototype[o].call(a,...l)}}):Object.keys(n).forEach(o=>{try{ah(n,o,n[o])}catch{}})}const r=e.$;r&&e===r.proxy?(ah(r.ctx,t,n),r.accessCache=Object.create(null)):So(e)?e[t]=n:ah(e,t,n)}function ah(e,t,n){n=ln(n)?ls(n):n,Object.defineProperty(e,t,{enumerable:!0,configurable:!0,get(){return ri(e,"get",t),n},set(r){n=ln(r)?ls(r):r,qa(e,"set",t,r)}})}function NN(){return{app:null,config:{isNativeTag:rU,performance:!1,globalProperties:{},optionMergeStrategies:{},errorHandler:void 0,warnHandler:void 0,compilerOptions:{}},mixins:[],components:{},directives:{},provides:Object.create(null),optionsCache:new WeakMap,propsCache:new WeakMap,emitsCache:new WeakMap}}let DG=0;function xG(e,t){return function(r,a=null){Ft(r)||(r=sn({},r)),a!=null&&!ln(a)&&(a=null);const o=NN(),l=new WeakSet;let u=!1;const c=o.app={_uid:DG++,_component:r,_props:a,_container:null,_context:o,_instance:null,version:ZN,get config(){return o.config},set config(d){},use(d,...S){return l.has(d)||(d&&Ft(d.install)?(l.add(d),d.install(c,...S)):Ft(d)&&(l.add(d),d(c,...S))),c},mixin(d){return o.mixins.includes(d)||o.mixins.push(d),c},component(d,S){return S?(o.components[d]=S,c):o.components[d]},directive(d,S){return S?(o.directives[d]=S,c):o.directives[d]},mount(d,S,_){if(!u){const E=En(r,a);return E.appContext=o,S&&t?t(E,d):e(E,d,_),u=!0,c._container=d,d.__vue_app__=c,Lf(E.component)||E.component.proxy}},unmount(){u&&(e(null,c._container),delete c._container.__vue_app__)},provide(d,S){return o.provides[d]=S,c},runWithContext(d){ac=c;try{return d()}finally{ac=null}}};return TG(c,o,e),c}}let ac=null;function IN(e,t){if(Xn){let n=Xn.provides;const r=Xn.parent&&Xn.parent.provides;r===n&&(n=Xn.provides=Object.create(r)),n[e]=t}}function Gs(e,t,n=!1){const r=Xn||Yn;if(r||ac){const a=r?r.parent==null?r.vnode.appContext&&r.vnode.appContext.provides:r.parent.provides:ac._context.provides;if(a&&e in a)return a[e];if(arguments.length>1)return n&&Ft(t)?t.call(r&&r.proxy):t}}function wG(){return!!(Xn||Yn||ac)}function LG(e,t,n){return new Proxy({},{get(r,a){if(a==="$options")return Tc(e);if(a in t)return t[a];const o=e.type.inject;if(o){if(Rt(o)){if(o.includes(a))return Gs(a)}else if(a in o)return Gs(a)}}})}function DN(e,t){return!!(e==="is"||(e==="class"||e==="style")&&Sn("INSTANCE_ATTRS_CLASS_STYLE",t)||Co(e)&&Sn("INSTANCE_LISTENERS",t)||e.startsWith("routerView")||e==="registerRouteInstance")}function MG(e,t,n,r=!1){const a={},o={};Ad(o,Df,1),e.propsDefaults=Object.create(null),xN(e,t,a,o);for(const l in e.propsOptions[0])l in a||(a[l]=void 0);n?e.props=r?a:PR(a):e.type.props?e.props=a:e.props=o,e.attrs=o}function kG(e,t,n,r){const{props:a,attrs:o,vnode:{patchFlag:l}}=e,u=pn(a),[c]=e.propsOptions;let d=!1;if((r||l>0)&&!(l&16)){if(l&8){const S=e.vnode.dynamicProps;for(let _=0;_<S.length;_++){let E=S[_];if(Af(e.emitsOptions,E))continue;const T=t[E];if(c)if(_n(o,E))T!==o[E]&&(o[E]=T,d=!0);else{const y=ni(E);a[y]=Yh(c,u,y,T,e,!1)}else{if(Co(E)&&E.endsWith("Native"))E=E.slice(0,-6);else if(DN(E,e))continue;T!==o[E]&&(o[E]=T,d=!0)}}}}else{xN(e,t,a,o)&&(d=!0);let S;for(const _ in u)(!t||!_n(t,_)&&((S=ei(_))===_||!_n(t,S)))&&(c?n&&(n[_]!==void 0||n[S]!==void 0)&&(a[_]=Yh(c,u,_,void 0,e,!0)):delete a[_]);if(o!==u)for(const _ in o)(!t||!_n(t,_)&&!_n(t,_+"Native"))&&(delete o[_],d=!0)}d&&qa(e,"set","$attrs")}function xN(e,t,n,r){const[a,o]=e.propsOptions;let l=!1,u;if(t)for(let c in t){if(Nl(c)||(c.startsWith("onHook:")&&yo("INSTANCE_EVENT_HOOKS",e,c.slice(2).toLowerCase()),c==="inline-template"))continue;const d=t[c];let S;if(a&&_n(a,S=ni(c)))!o||!o.includes(S)?n[S]=d:(u||(u={}))[S]=d;else if(!Af(e.emitsOptions,c)){if(Co(c)&&c.endsWith("Native"))c=c.slice(0,-6);else if(DN(c,e))continue;(!(c in r)||d!==r[c])&&(r[c]=d,l=!0)}}if(o){const c=pn(n),d=u||yn;for(let S=0;S<o.length;S++){const _=o[S];n[_]=Yh(a,c,_,d[_],e,!_n(d,_))}}return l}function Yh(e,t,n,r,a,o){const l=e[n];if(l!=null){const u=_n(l,"default");if(u&&r===void 0){const c=l.default;if(l.type!==Function&&!l.skipFactory&&Ft(c)){const{propsDefaults:d}=a;n in d?r=d[n]:(us(a),r=d[n]=c.call(Sn("PROPS_DEFAULT_THIS",a)?LG(a,t):null,t),ts())}else r=c}l[0]&&(o&&!u?r=!1:l[1]&&(r===""||r===ei(n))&&(r=!0))}return r}function wN(e,t,n=!1){const r=t.propsCache,a=r.get(e);if(a)return a;const o=e.props,l={},u=[];let c=!1;if(!Ft(e)){const S=_=>{Ft(_)&&(_=_.options),c=!0;const[E,T]=wN(_,t,!0);sn(l,E),T&&u.push(...T)};!n&&t.mixins.length&&t.mixins.forEach(S),e.extends&&S(e.extends),e.mixins&&e.mixins.forEach(S)}if(!o&&!c)return ln(e)&&r.set(e,Ol),Ol;if(Rt(o))for(let S=0;S<o.length;S++){const _=ni(o[S]);wC(_)&&(l[_]=yn)}else if(o)for(const S in o){const _=ni(S);if(wC(_)){const E=o[S],T=l[_]=Rt(E)||Ft(E)?{type:E}:sn({},E);if(T){const y=kC(Boolean,T.type),M=kC(String,T.type);T[0]=y>-1,T[1]=M<0||y<M,(y>-1||_n(T,"default"))&&u.push(_)}}}const d=[l,u];return ln(e)&&r.set(e,d),d}function wC(e){return e[0]!=="$"}function LC(e){const t=e&&e.toString().match(/^\s*(function|class) (\w+)/);return t?t[2]:e===null?"null":""}function MC(e,t){return LC(e)===LC(t)}function kC(e,t){return Rt(t)?t.findIndex(n=>MC(n,e)):Ft(t)&&MC(t,e)?0:-1}const LN=e=>e[0]==="_"||e==="$stable",mS=e=>Rt(e)?e.map(Pi):[Pi(e)],PG=(e,t,n)=>{if(t._n)return t;const r=sS((...a)=>mS(t(...a)),n);return r._c=!1,r},MN=(e,t,n)=>{const r=e._ctx;for(const a in e){if(LN(a))continue;const o=e[a];if(Ft(o))t[a]=PG(a,o,r);else if(o!=null){const l=mS(o);t[a]=()=>l}}},kN=(e,t)=>{const n=mS(t);e.slots.default=()=>n},FG=(e,t)=>{if(e.vnode.shapeFlag&32){const n=t._;n?(e.slots=pn(t),Ad(t,"_",n)):MN(t,e.slots={})}else e.slots={},t&&kN(e,t);Ad(e.slots,Df,1)},BG=(e,t,n)=>{const{vnode:r,slots:a}=e;let o=!0,l=yn;if(r.shapeFlag&32){const u=t._;u?n&&u===1?o=!1:(sn(a,t),!n&&u===1&&delete a._):(o=!t.$stable,MN(t,a)),l=t}else t&&(kN(e,t),l={default:1});if(o)for(const u in a)!LN(u)&&l[u]==null&&delete a[u]};function wd(e,t,n,r,a=!1){if(Rt(e)){e.forEach((E,T)=>wd(E,t&&(Rt(t)?t[T]:t),n,r,a));return}if(Fs(r)&&!a)return;const o=r.shapeFlag&4?Lf(r.component)||r.component.proxy:r.el,l=a?null:o,{i:u,r:c}=e,d=t&&t.r,S=u.refs===yn?u.refs={}:u.refs,_=u.setupState;if(d!=null&&d!==c&&(xn(d)?(S[d]=null,_n(_,d)&&(_[d]=null)):sr(d)&&(d.value=null)),Ft(c))Ya(c,u,12,[l,S]);else{const E=xn(c),T=sr(c);if(E||T){const y=()=>{if(e.f){const M=E?_n(_,c)?_[c]:S[c]:c.value;a?Rt(M)&&WE(M,o):Rt(M)?M.includes(o)||M.push(o):E?(S[c]=[o],_n(_,c)&&(_[c]=S[c])):(c.value=[o],e.k&&(S[e.k]=c.value))}else E?(S[c]=l,_n(_,c)&&(_[c]=l)):T&&(c.value=l,e.k&&(S[e.k]=l))};l?(y.id=-1,$n(y,n)):y()}}}let Wo=!1;const od=e=>/svg/.test(e.namespaceURI)&&e.tagName!=="foreignObject",sd=e=>e.nodeType===8;function UG(e){const{mt:t,p:n,o:{patchProp:r,createText:a,nextSibling:o,parentNode:l,remove:u,insert:c,createComment:d}}=e,S=(N,R)=>{if(!R.hasChildNodes()){n(null,N,R),Dd(),R._vnode=N;return}Wo=!1,_(R.firstChild,N,null,null,null),Dd(),R._vnode=N,Wo&&console.error("Hydration completed but contains mismatches.")},_=(N,R,L,I,h,k=!1)=>{const F=sd(N)&&N.data==="[",z=()=>M(N,R,L,I,h,F),{type:K,ref:ue,shapeFlag:Z,patchFlag:fe}=R;let V=N.nodeType;R.el=N,fe===-2&&(k=!1,R.dynamicChildren=null);let ne=null;switch(K){case js:V!==3?R.children===""?(c(R.el=a(""),l(N),N),ne=N):ne=z():(N.data!==R.children&&(Wo=!0,N.data=R.children),ne=o(N));break;case Dr:O(N)?(ne=o(N),A(R.el=N.content.firstChild,N,L)):V!==8||F?ne=z():ne=o(N);break;case Hs:if(F&&(N=o(N),V=N.nodeType),V===1||V===3){ne=N;const te=!R.children.length;for(let G=0;G<R.staticCount;G++)te&&(R.children+=ne.nodeType===1?ne.outerHTML:ne.data),G===R.staticCount-1&&(R.anchor=ne),ne=o(ne);return F?o(ne):ne}else z();break;case hr:F?ne=y(N,R,L,I,h,k):ne=z();break;default:if(Z&1)(V!==1||R.type.toLowerCase()!==N.tagName.toLowerCase())&&!O(N)?ne=z():ne=E(N,R,L,I,h,k);else if(Z&6){R.slotScopeIds=h;const te=l(N);if(F?ne=v(N):sd(N)&&N.data==="teleport start"?ne=v(N,N.data,"teleport end"):ne=o(N),t(R,te,null,L,I,od(te),k),Fs(R)){let G;F?(G=En(hr),G.anchor=ne?ne.previousSibling:te.lastChild):G=N.nodeType===3?ql(""):En("div"),G.el=N,R.component.subTree=G}}else Z&64?V!==8?ne=z():ne=R.type.hydrate(N,R,L,I,h,k,e,T):Z&128&&(ne=R.type.hydrate(N,R,L,I,od(l(N)),h,k,e,_))}return ue!=null&&wd(ue,null,I,R),ne},E=(N,R,L,I,h,k)=>{k=k||!!R.dynamicChildren;const{type:F,props:z,patchFlag:K,shapeFlag:ue,dirs:Z,transition:fe}=R,V=F==="input"&&Z||F==="option";if(V||K!==-1){if(Z&&Ba(R,null,L,"created"),z)if(V||!k||K&48)for(const G in z)(V&&G.endsWith("value")||Co(G)&&!Nl(G))&&r(N,G,null,z[G],!1,void 0,L);else z.onClick&&r(N,"onClick",null,z.onClick,!1,void 0,L);let ne;(ne=z&&z.onVnodeBeforeMount)&&Ei(ne,L,R);let te=!1;if(O(N)){te=UN(I,fe)&&L&&L.vnode.props&&L.vnode.props.appear;const G=N.content.firstChild;te&&fe.beforeEnter(G),A(G,N,L),R.el=N=G}if(Z&&Ba(R,null,L,"beforeMount"),((ne=z&&z.onVnodeMounted)||Z||te)&&jR(()=>{ne&&Ei(ne,L,R),te&&fe.enter(N),Z&&Ba(R,null,L,"mounted")},I),ue&16&&!(z&&(z.innerHTML||z.textContent))){let G=T(N.firstChild,R,N,L,I,h,k);for(;G;){Wo=!0;const se=G;G=G.nextSibling,u(se)}}else ue&8&&N.textContent!==R.children&&(Wo=!0,N.textContent=R.children)}return N.nextSibling},T=(N,R,L,I,h,k,F)=>{F=F||!!R.dynamicChildren;const z=R.children,K=z.length;for(let ue=0;ue<K;ue++){const Z=F?z[ue]:z[ue]=Pi(z[ue]);if(N)N=_(N,Z,I,h,k,F);else{if(Z.type===js&&!Z.children)continue;Wo=!0,n(null,Z,L,null,I,h,od(L),k)}}return N},y=(N,R,L,I,h,k)=>{const{slotScopeIds:F}=R;F&&(h=h?h.concat(F):F);const z=l(N),K=T(o(N),R,z,L,I,h,k);return K&&sd(K)&&K.data==="]"?o(R.anchor=K):(Wo=!0,c(R.anchor=d("]"),z,K),K)},M=(N,R,L,I,h,k)=>{if(Wo=!0,R.el=null,k){const K=v(N);for(;;){const ue=o(N);if(ue&&ue!==K)u(ue);else break}}const F=o(N),z=l(N);return u(N),n(null,R,z,F,L,I,od(z),h),F},v=(N,R="[",L="]")=>{let I=0;for(;N;)if(N=o(N),N&&sd(N)&&(N.data===R&&I++,N.data===L)){if(I===0)return o(N);I--}return N},A=(N,R,L)=>{const I=R.parentNode;I&&I.replaceChild(N,R);let h=L;for(;h;)h.vnode.el===R&&(h.vnode.el=h.subTree.el=N),h=h.parent},O=N=>N.nodeType===1&&N.tagName.toLowerCase()==="template";return[S,_]}const $n=jR;function PN(e){return BN(e)}function FN(e){return BN(e,UG)}function BN(e,t){const n=Lh();n.__VUE__=!0;const{insert:r,remove:a,patchProp:o,createElement:l,createText:u,createComment:c,setText:d,setElementText:S,parentNode:_,nextSibling:E,setScopeId:T=vi,insertStaticContent:y}=e,M=(ce,Ee,He,we=null,ze=null,pe=null,Re=!1,Ne=null,Ie=!!Ee.dynamicChildren)=>{if(ce===Ee)return;ce&&!ba(ce,Ee)&&(we=bt(ce),oe(ce,ze,pe,!0),ce=null),Ee.patchFlag===-2&&(Ie=!1,Ee.dynamicChildren=null);const{type:Ue,ref:Ve,shapeFlag:lt}=Ee;switch(Ue){case js:v(ce,Ee,He,we);break;case Dr:A(ce,Ee,He,we);break;case Hs:ce==null&&O(Ee,He,we,Re);break;case hr:ue(ce,Ee,He,we,ze,pe,Re,Ne,Ie);break;default:lt&1?L(ce,Ee,He,we,ze,pe,Re,Ne,Ie):lt&6?Z(ce,Ee,He,we,ze,pe,Re,Ne,Ie):(lt&64||lt&128)&&Ue.process(ce,Ee,He,we,ze,pe,Re,Ne,Ie,ct)}Ve!=null&&ze&&wd(Ve,ce&&ce.ref,pe,Ee||ce,!Ee)},v=(ce,Ee,He,we)=>{if(ce==null)r(Ee.el=u(Ee.children),He,we);else{const ze=Ee.el=ce.el;Ee.children!==ce.children&&d(ze,Ee.children)}},A=(ce,Ee,He,we)=>{ce==null?r(Ee.el=c(Ee.children||""),He,we):Ee.el=ce.el},O=(ce,Ee,He,we)=>{[ce.el,ce.anchor]=y(ce.children,Ee,He,we,ce.el,ce.anchor)},N=({el:ce,anchor:Ee},He,we)=>{let ze;for(;ce&&ce!==Ee;)ze=E(ce),r(ce,He,we),ce=ze;r(Ee,He,we)},R=({el:ce,anchor:Ee})=>{let He;for(;ce&&ce!==Ee;)He=E(ce),a(ce),ce=He;a(Ee)},L=(ce,Ee,He,we,ze,pe,Re,Ne,Ie)=>{Re=Re||Ee.type==="svg",ce==null?I(Ee,He,we,ze,pe,Re,Ne,Ie):F(ce,Ee,ze,pe,Re,Ne,Ie)},I=(ce,Ee,He,we,ze,pe,Re,Ne)=>{let Ie,Ue;const{type:Ve,props:lt,shapeFlag:ge,transition:de,dirs:be}=ce;if(Ie=ce.el=l(ce.type,pe,lt&<.is,lt),ge&8?S(Ie,ce.children):ge&16&&k(ce.children,Ie,null,we,ze,pe&&Ve!=="foreignObject",Re,Ne),be&&Ba(ce,null,we,"created"),h(Ie,ce,ce.scopeId,Re,we),lt){for(const ee in lt)ee!=="value"&&!Nl(ee)&&o(Ie,ee,null,lt[ee],pe,ce.children,we,ze,rt);"value"in lt&&o(Ie,"value",null,lt.value),(Ue=lt.onVnodeBeforeMount)&&Ei(Ue,we,ce)}be&&Ba(ce,null,we,"beforeMount");const H=UN(ze,de);H&&de.beforeEnter(Ie),r(Ie,Ee,He),((Ue=lt&<.onVnodeMounted)||H||be)&&$n(()=>{Ue&&Ei(Ue,we,ce),H&&de.enter(Ie),be&&Ba(ce,null,we,"mounted")},ze)},h=(ce,Ee,He,we,ze)=>{if(He&&T(ce,He),we)for(let pe=0;pe<we.length;pe++)T(ce,we[pe]);if(ze){let pe=ze.subTree;if(Ee===pe){const Re=ze.vnode;h(ce,Re,Re.scopeId,Re.slotScopeIds,ze.parent)}}},k=(ce,Ee,He,we,ze,pe,Re,Ne,Ie=0)=>{for(let Ue=Ie;Ue<ce.length;Ue++){const Ve=ce[Ue]=Ne?$o(ce[Ue]):Pi(ce[Ue]);M(null,Ve,Ee,He,we,ze,pe,Re,Ne)}},F=(ce,Ee,He,we,ze,pe,Re)=>{const Ne=Ee.el=ce.el;let{patchFlag:Ie,dynamicChildren:Ue,dirs:Ve}=Ee;Ie|=ce.patchFlag&16;const lt=ce.props||yn,ge=Ee.props||yn;let de;He&&vs(He,!1),(de=ge.onVnodeBeforeUpdate)&&Ei(de,He,Ee,ce),Ve&&Ba(Ee,ce,He,"beforeUpdate"),He&&vs(He,!0);const be=ze&&Ee.type!=="foreignObject";if(Ue?z(ce.dynamicChildren,Ue,Ne,He,we,be,pe):Re||G(ce,Ee,Ne,null,He,we,be,pe,!1),Ie>0){if(Ie&16)K(Ne,Ee,lt,ge,He,we,ze);else if(Ie&2&<.class!==ge.class&&o(Ne,"class",null,ge.class,ze),Ie&4&&o(Ne,"style",lt.style,ge.style,ze),Ie&8){const H=Ee.dynamicProps;for(let ee=0;ee<H.length;ee++){const _e=H[ee],U=lt[_e],Q=ge[_e];(Q!==U||_e==="value")&&o(Ne,_e,U,Q,ze,ce.children,He,we,rt)}}Ie&1&&ce.children!==Ee.children&&S(Ne,Ee.children)}else!Re&&Ue==null&&K(Ne,Ee,lt,ge,He,we,ze);((de=ge.onVnodeUpdated)||Ve)&&$n(()=>{de&&Ei(de,He,Ee,ce),Ve&&Ba(Ee,ce,He,"updated")},we)},z=(ce,Ee,He,we,ze,pe,Re)=>{for(let Ne=0;Ne<Ee.length;Ne++){const Ie=ce[Ne],Ue=Ee[Ne],Ve=Ie.el&&(Ie.type===hr||!ba(Ie,Ue)||Ie.shapeFlag&70)?_(Ie.el):He;M(Ie,Ue,Ve,null,we,ze,pe,Re,!0)}},K=(ce,Ee,He,we,ze,pe,Re)=>{if(He!==we){if(He!==yn)for(const Ne in He)!Nl(Ne)&&!(Ne in we)&&o(ce,Ne,He[Ne],null,Re,Ee.children,ze,pe,rt);for(const Ne in we){if(Nl(Ne))continue;const Ie=we[Ne],Ue=He[Ne];Ie!==Ue&&Ne!=="value"&&o(ce,Ne,Ue,Ie,Re,Ee.children,ze,pe,rt)}"value"in we&&o(ce,"value",He.value,we.value)}},ue=(ce,Ee,He,we,ze,pe,Re,Ne,Ie)=>{const Ue=Ee.el=ce?ce.el:u(""),Ve=Ee.anchor=ce?ce.anchor:u("");let{patchFlag:lt,dynamicChildren:ge,slotScopeIds:de}=Ee;de&&(Ne=Ne?Ne.concat(de):de),ce==null?(r(Ue,He,we),r(Ve,He,we),k(Ee.children,He,Ve,ze,pe,Re,Ne,Ie)):lt>0&<&64&&ge&&ce.dynamicChildren?(z(ce.dynamicChildren,ge,He,ze,pe,Re,Ne),(Ee.key!=null||ze&&Ee===ze.subTree)&&gS(ce,Ee,!0)):G(ce,Ee,He,Ve,ze,pe,Re,Ne,Ie)},Z=(ce,Ee,He,we,ze,pe,Re,Ne,Ie)=>{Ee.slotScopeIds=Ne,ce==null?Ee.shapeFlag&512?ze.ctx.activate(Ee,He,we,Re,Ie):fe(Ee,He,we,ze,pe,Re,Ie):V(ce,Ee,Ie)},fe=(ce,Ee,He,we,ze,pe,Re)=>{const Ne=ce.isCompatRoot&&ce.component,Ie=Ne||(ce.component=SS(ce,we,ze));if(bc(ce)&&(Ie.ctx.renderer=ct),Ne||vS(Ie),Ie.asyncDep){if(ze&&ze.registerDep(Ie,ne),!ce.el){const Ue=Ie.subTree=En(Dr);A(null,Ue,Ee,He)}return}ne(Ie,ce,Ee,He,ze,pe,Re)},V=(ce,Ee,He)=>{const we=Ee.component=ce.component;if(y3(ce,Ee,He))if(we.asyncDep&&!we.asyncResolved){te(we,Ee,He);return}else we.next=Ee,l3(we.update),we.update();else Ee.el=ce.el,we.vnode=Ee},ne=(ce,Ee,He,we,ze,pe,Re)=>{const Ne=()=>{if(ce.isMounted){let{next:Ve,bu:lt,u:ge,parent:de,vnode:be}=ce,H=Ve,ee;vs(ce,!1),Ve?(Ve.el=be.el,te(ce,Ve,Re)):Ve=be,lt&&Jo(lt),(ee=Ve.props&&Ve.props.onVnodeBeforeUpdate)&&Ei(ee,de,Ve,be),Sn("INSTANCE_EVENT_HOOKS",ce)&&ce.emit("hook:beforeUpdate"),vs(ce,!0);const _e=pd(ce),U=ce.subTree;ce.subTree=_e,M(U,_e,_(U.el),bt(U),ce,ze,pe),Ve.el=_e.el,H===null&&lS(ce,_e.el),ge&&$n(ge,ze),(ee=Ve.props&&Ve.props.onVnodeUpdated)&&$n(()=>Ei(ee,de,Ve,be),ze),Sn("INSTANCE_EVENT_HOOKS",ce)&&$n(()=>ce.emit("hook:updated"),ze)}else{let Ve;const{el:lt,props:ge}=Ee,{bm:de,m:be,parent:H}=ce,ee=Fs(Ee);if(vs(ce,!1),de&&Jo(de),!ee&&(Ve=ge&&ge.onVnodeBeforeMount)&&Ei(Ve,H,Ee),Sn("INSTANCE_EVENT_HOOKS",ce)&&ce.emit("hook:beforeMount"),vs(ce,!0),lt&&nt){const _e=()=>{ce.subTree=pd(ce),nt(lt,ce.subTree,ce,ze,null)};ee?Ee.type.__asyncLoader().then(()=>!ce.isUnmounted&&_e()):_e()}else{const _e=ce.subTree=pd(ce);M(null,_e,He,we,ce,ze,pe),Ee.el=_e.el}if(be&&$n(be,ze),!ee&&(Ve=ge&&ge.onVnodeMounted)){const _e=Ee;$n(()=>Ei(Ve,H,_e),ze)}Sn("INSTANCE_EVENT_HOOKS",ce)&&$n(()=>ce.emit("hook:mounted"),ze),(Ee.shapeFlag&256||H&&Fs(H.vnode)&&H.vnode.shapeFlag&256)&&(ce.a&&$n(ce.a,ze),Sn("INSTANCE_EVENT_HOOKS",ce)&&$n(()=>ce.emit("hook:activated"),ze)),ce.isMounted=!0,Ee=He=we=null}},Ie=ce.effect=new Gl(Ne,()=>Tf(Ue),ce.scope),Ue=ce.update=()=>Ie.run();Ue.id=ce.uid,vs(ce,!0),Ue()},te=(ce,Ee,He)=>{Ee.component=ce;const we=ce.vnode.props;ce.vnode=Ee,ce.next=null,kG(ce,Ee.props,we,He),BG(ce,Ee.children,He),nu(),SC(),ru()},G=(ce,Ee,He,we,ze,pe,Re,Ne,Ie=!1)=>{const Ue=ce&&ce.children,Ve=ce?ce.shapeFlag:0,lt=Ee.children,{patchFlag:ge,shapeFlag:de}=Ee;if(ge>0){if(ge&128){ve(Ue,lt,He,we,ze,pe,Re,Ne,Ie);return}else if(ge&256){se(Ue,lt,He,we,ze,pe,Re,Ne,Ie);return}}de&8?(Ve&16&&rt(Ue,ze,pe),lt!==Ue&&S(He,lt)):Ve&16?de&16?ve(Ue,lt,He,we,ze,pe,Re,Ne,Ie):rt(Ue,ze,pe,!0):(Ve&8&&S(He,""),de&16&&k(lt,He,we,ze,pe,Re,Ne,Ie))},se=(ce,Ee,He,we,ze,pe,Re,Ne,Ie)=>{ce=ce||Ol,Ee=Ee||Ol;const Ue=ce.length,Ve=Ee.length,lt=Math.min(Ue,Ve);let ge;for(ge=0;ge<lt;ge++){const de=Ee[ge]=Ie?$o(Ee[ge]):Pi(Ee[ge]);M(ce[ge],de,He,null,ze,pe,Re,Ne,Ie)}Ue>Ve?rt(ce,ze,pe,!0,!1,lt):k(Ee,He,we,ze,pe,Re,Ne,Ie,lt)},ve=(ce,Ee,He,we,ze,pe,Re,Ne,Ie)=>{let Ue=0;const Ve=Ee.length;let lt=ce.length-1,ge=Ve-1;for(;Ue<=lt&&Ue<=ge;){const de=ce[Ue],be=Ee[Ue]=Ie?$o(Ee[Ue]):Pi(Ee[Ue]);if(ba(de,be))M(de,be,He,null,ze,pe,Re,Ne,Ie);else break;Ue++}for(;Ue<=lt&&Ue<=ge;){const de=ce[lt],be=Ee[ge]=Ie?$o(Ee[ge]):Pi(Ee[ge]);if(ba(de,be))M(de,be,He,null,ze,pe,Re,Ne,Ie);else break;lt--,ge--}if(Ue>lt){if(Ue<=ge){const de=ge+1,be=de<Ve?Ee[de].el:we;for(;Ue<=ge;)M(null,Ee[Ue]=Ie?$o(Ee[Ue]):Pi(Ee[Ue]),He,be,ze,pe,Re,Ne,Ie),Ue++}}else if(Ue>ge)for(;Ue<=lt;)oe(ce[Ue],ze,pe,!0),Ue++;else{const de=Ue,be=Ue,H=new Map;for(Ue=be;Ue<=ge;Ue++){const je=Ee[Ue]=Ie?$o(Ee[Ue]):Pi(Ee[Ue]);je.key!=null&&H.set(je.key,Ue)}let ee,_e=0;const U=ge-be+1;let Q=!1,he=0;const Le=new Array(U);for(Ue=0;Ue<U;Ue++)Le[Ue]=0;for(Ue=de;Ue<=lt;Ue++){const je=ce[Ue];if(_e>=U){oe(je,ze,pe,!0);continue}let at;if(je.key!=null)at=H.get(je.key);else for(ee=be;ee<=ge;ee++)if(Le[ee-be]===0&&ba(je,Ee[ee])){at=ee;break}at===void 0?oe(je,ze,pe,!0):(Le[at-be]=Ue+1,at>=he?he=at:Q=!0,M(je,Ee[at],He,null,ze,pe,Re,Ne,Ie),_e++)}const Xe=Q?GG(Le):Ol;for(ee=Xe.length-1,Ue=U-1;Ue>=0;Ue--){const je=be+Ue,at=Ee[je],ke=je+1<Ve?Ee[je+1].el:we;Le[Ue]===0?M(null,at,He,ke,ze,pe,Re,Ne,Ie):Q&&(ee<0||Ue!==Xe[ee]?Ge(at,He,ke,2):ee--)}}},Ge=(ce,Ee,He,we,ze=null)=>{const{el:pe,type:Re,transition:Ne,children:Ie,shapeFlag:Ue}=ce;if(Ue&6){Ge(ce.component.subTree,Ee,He,we);return}if(Ue&128){ce.suspense.move(Ee,He,we);return}if(Ue&64){Re.move(ce,Ee,He,ct);return}if(Re===hr){r(pe,Ee,He);for(let lt=0;lt<Ie.length;lt++)Ge(Ie[lt],Ee,He,we);r(ce.anchor,Ee,He);return}if(Re===Hs){N(ce,Ee,He);return}if(we!==2&&Ue&1&&Ne)if(we===0)Ne.beforeEnter(pe),r(pe,Ee,He),$n(()=>Ne.enter(pe),ze);else{const{leave:lt,delayLeave:ge,afterLeave:de}=Ne,be=()=>r(pe,Ee,He),H=()=>{lt(pe,()=>{be(),de&&de()})};ge?ge(pe,be,H):H()}else r(pe,Ee,He)},oe=(ce,Ee,He,we=!1,ze=!1)=>{const{type:pe,props:Re,ref:Ne,children:Ie,dynamicChildren:Ue,shapeFlag:Ve,patchFlag:lt,dirs:ge}=ce;if(Ne!=null&&wd(Ne,null,He,ce,!0),Ve&256){Ee.ctx.deactivate(ce);return}const de=Ve&1&&ge,be=!Fs(ce);let H;if(be&&(H=Re&&Re.onVnodeBeforeUnmount)&&Ei(H,Ee,ce),Ve&6)tt(ce.component,He,we);else{if(Ve&128){ce.suspense.unmount(He,we);return}de&&Ba(ce,null,Ee,"beforeUnmount"),Ve&64?ce.type.remove(ce,Ee,He,ze,ct,we):Ue&&(pe!==hr||lt>0&<&64)?rt(Ue,Ee,He,!1,!0):(pe===hr&<&384||!ze&&Ve&16)&&rt(Ie,Ee,He),we&&W(ce)}(be&&(H=Re&&Re.onVnodeUnmounted)||de)&&$n(()=>{H&&Ei(H,Ee,ce),de&&Ba(ce,null,Ee,"unmounted")},He)},W=ce=>{const{type:Ee,el:He,anchor:we,transition:ze}=ce;if(Ee===hr){Oe(He,we);return}if(Ee===Hs){R(ce);return}const pe=()=>{a(He),ze&&!ze.persisted&&ze.afterLeave&&ze.afterLeave()};if(ce.shapeFlag&1&&ze&&!ze.persisted){const{leave:Re,delayLeave:Ne}=ze,Ie=()=>Re(He,pe);Ne?Ne(ce.el,pe,Ie):Ie()}else pe()},Oe=(ce,Ee)=>{let He;for(;ce!==Ee;)He=E(ce),a(ce),ce=He;a(Ee)},tt=(ce,Ee,He)=>{const{bum:we,scope:ze,update:pe,subTree:Re,um:Ne}=ce;we&&Jo(we),Sn("INSTANCE_EVENT_HOOKS",ce)&&ce.emit("hook:beforeDestroy"),ze.stop(),pe&&(pe.active=!1,oe(Re,ce,Ee,He)),Ne&&$n(Ne,Ee),Sn("INSTANCE_EVENT_HOOKS",ce)&&$n(()=>ce.emit("hook:destroyed"),Ee),$n(()=>{ce.isUnmounted=!0},Ee),Ee&&Ee.pendingBranch&&!Ee.isUnmounted&&ce.asyncDep&&!ce.asyncResolved&&ce.suspenseId===Ee.pendingId&&(Ee.deps--,Ee.deps===0&&Ee.resolve())},rt=(ce,Ee,He,we=!1,ze=!1,pe=0)=>{for(let Re=pe;Re<ce.length;Re++)oe(ce[Re],Ee,He,we,ze)},bt=ce=>ce.shapeFlag&6?bt(ce.component.subTree):ce.shapeFlag&128?ce.suspense.next():E(ce.anchor||ce.el),dt=(ce,Ee,He)=>{ce==null?Ee._vnode&&oe(Ee._vnode,null,null,!0):M(Ee._vnode||null,ce,Ee,null,null,null,He),SC(),Dd(),Ee._vnode=ce},ct={p:M,um:oe,m:Ge,r:W,mt:fe,mc:k,pc:G,pbc:z,n:bt,o:e};let Ze,nt;return t&&([Ze,nt]=t(ct)),{render:dt,hydrate:Ze,createApp:xG(dt,Ze)}}function vs({effect:e,update:t},n){e.allowRecurse=t.allowRecurse=n}function UN(e,t){return(!e||e&&!e.pendingBranch)&&t&&!t.persisted}function gS(e,t,n=!1){const r=e.children,a=t.children;if(Rt(r)&&Rt(a))for(let o=0;o<r.length;o++){const l=r[o];let u=a[o];u.shapeFlag&1&&!u.dynamicChildren&&((u.patchFlag<=0||u.patchFlag===32)&&(u=a[o]=$o(a[o]),u.el=l.el),n||gS(l,u)),u.type===js&&(u.el=l.el)}}function GG(e){const t=e.slice(),n=[0];let r,a,o,l,u;const c=e.length;for(r=0;r<c;r++){const d=e[r];if(d!==0){if(a=n[n.length-1],e[a]<d){t[r]=a,n.push(r);continue}for(o=0,l=n.length-1;o<l;)u=o+l>>1,e[n[u]]<d?o=u+1:l=u;d<e[n[o]]&&(o>0&&(t[r]=n[o-1]),n[o]=r)}}for(o=n.length,l=n[o-1];o-- >0;)n[o]=l,l=t[l];return n}const HG=e=>e.__isTeleport,Pu=e=>e&&(e.disabled||e.disabled===""),PC=e=>typeof SVGElement<"u"&&e instanceof SVGElement,Wh=(e,t)=>{const n=e&&e.to;return xn(n)?t?t(n):null:n},qG={__isTeleport:!0,process(e,t,n,r,a,o,l,u,c,d){const{mc:S,pc:_,pbc:E,o:{insert:T,querySelector:y,createText:M,createComment:v}}=d,A=Pu(t.props);let{shapeFlag:O,children:N,dynamicChildren:R}=t;if(e==null){const L=t.el=M(""),I=t.anchor=M("");T(L,n,r),T(I,n,r);const h=t.target=Wh(t.props,y),k=t.targetAnchor=M("");h&&(T(k,h),l=l||PC(h));const F=(z,K)=>{O&16&&S(N,z,K,a,o,l,u,c)};A?F(n,I):h&&F(h,k)}else{t.el=e.el;const L=t.anchor=e.anchor,I=t.target=e.target,h=t.targetAnchor=e.targetAnchor,k=Pu(e.props),F=k?n:I,z=k?L:h;if(l=l||PC(I),R?(E(e.dynamicChildren,R,F,a,o,l,u),gS(e,t,!0)):c||_(e,t,F,z,a,o,l,u,!1),A)k?t.props&&e.props&&t.props.to!==e.props.to&&(t.props.to=e.props.to):ld(t,n,L,d,1);else if((t.props&&t.props.to)!==(e.props&&e.props.to)){const K=t.target=Wh(t.props,y);K&&ld(t,K,null,d,0)}else k&&ld(t,I,h,d,1)}GN(t)},remove(e,t,n,r,{um:a,o:{remove:o}},l){const{shapeFlag:u,children:c,anchor:d,targetAnchor:S,target:_,props:E}=e;if(_&&o(S),l&&o(d),u&16){const T=l||!Pu(E);for(let y=0;y<c.length;y++){const M=c[y];a(M,t,n,T,!!M.dynamicChildren)}}},move:ld,hydrate:YG};function ld(e,t,n,{o:{insert:r},m:a},o=2){o===0&&r(e.targetAnchor,t,n);const{el:l,anchor:u,shapeFlag:c,children:d,props:S}=e,_=o===2;if(_&&r(l,t,n),(!_||Pu(S))&&c&16)for(let E=0;E<d.length;E++)a(d[E],t,n,2);_&&r(u,t,n)}function YG(e,t,n,r,a,o,{o:{nextSibling:l,parentNode:u,querySelector:c}},d){const S=t.target=Wh(t.props,c);if(S){const _=S._lpa||S.firstChild;if(t.shapeFlag&16)if(Pu(t.props))t.anchor=d(l(e),t,u(e),n,r,a,o),t.targetAnchor=_;else{t.anchor=l(e);let E=_;for(;E;)if(E=l(E),E&&E.nodeType===8&&E.data==="teleport anchor"){t.targetAnchor=E,S._lpa=t.targetAnchor&&l(t.targetAnchor);break}d(_,t,S,n,r,a,o)}GN(t)}return t.anchor&&l(t.anchor)}const WG=qG;function GN(e){const t=e.ctx;if(t&&t.ut){let n=e.children[0].el;for(;n&&n!==e.targetAnchor;)n.nodeType===1&&n.setAttribute("data-v-owner",t.uid),n=n.nextSibling;t.ut()}}const oh=new WeakMap;function VG(e){if(oh.has(e))return oh.get(e);let t,n;const r=new Promise((l,u)=>{t=l,n=u}),a=e(t,n);let o;return gf(a)?o=_d(()=>a):ln(a)&&!Bi(a)&&!Rt(a)?o=_d({loader:()=>a.component,loadingComponent:a.loading,errorComponent:a.error,delay:a.delay,timeout:a.timeout}):a==null?o=_d(()=>r):o=e,oh.set(e,o),o}function zG(e,t){return e.__isBuiltIn?e:(Ft(e)&&e.cid&&(e=e.options),Ft(e)&&yf("COMPONENT_ASYNC",t,e)?VG(e):ln(e)&&e.functional&&yo("COMPONENT_FUNCTIONAL",t,e)?W3(e):e)}const hr=Symbol.for("v-fgt"),js=Symbol.for("v-txt"),Dr=Symbol.for("v-cmt"),Hs=Symbol.for("v-stc"),Fu=[];let bi=null;function ki(e=!1){Fu.push(bi=e?null:[])}function HN(){Fu.pop(),bi=Fu[Fu.length-1]||null}let Xs=1;function Vh(e){Xs+=e}function qN(e){return e.dynamicChildren=Xs>0?bi||Ol:null,HN(),Xs>0&&bi&&bi.push(e),e}function Ma(e,t,n,r,a,o){return qN(on(e,t,n,r,a,o,!0))}function hS(e,t,n,r,a){return qN(En(e,t,n,r,a,!0))}function Bi(e){return e?e.__v_isVNode===!0:!1}function ba(e,t){return e.type===t.type&&e.key===t.key}function KG(e){}const Df="__vInternal",YN=({key:e})=>e!=null?e:null,md=({ref:e,ref_key:t,ref_for:n})=>(typeof e=="number"&&(e=""+e),e!=null?xn(e)||sr(e)||Ft(e)?{i:Yn,r:e,k:t,f:!!n}:e:null);function on(e,t=null,n=null,r=0,a=null,o=e===hr?0:1,l=!1,u=!1){const c={__v_isVNode:!0,__v_skip:!0,type:e,props:t,key:t&&YN(t),ref:t&&md(t),scopeId:wl,slotScopeIds:null,children:n,component:null,suspense:null,ssContent:null,ssFallback:null,dirs:null,transition:null,el:null,anchor:null,target:null,targetAnchor:null,staticCount:0,shapeFlag:o,patchFlag:r,dynamicProps:a,dynamicChildren:null,appContext:null,ctx:Yn};return u?(xf(c,n),o&128&&e.normalize(c)):n&&(c.shapeFlag|=xn(n)?8:16),Xs>0&&!l&&bi&&(c.patchFlag>0||o&6)&&c.patchFlag!==32&&bi.push(c),_3(c),gN(c),c}const En=$G;function $G(e,t=null,n=null,r=0,a=null,o=!1){if((!e||e===VR)&&(e=Dr),Bi(e)){const u=va(e,t,!0);return n&&xf(u,n),Xs>0&&!o&&bi&&(u.shapeFlag&6?bi[bi.indexOf(e)]=u:bi.push(u)),u.patchFlag|=-2,u}if(eH(e)&&(e=e.__vccOpts),e=zG(e,Yn),t){t=WN(t);let{class:u,style:c}=t;u&&!xn(u)&&(t.class=Va(u)),ln(c)&&(jE(c)&&!Rt(c)&&(c=sn({},c)),t.style=tu(c))}const l=xn(e)?1:QR(e)?128:HG(e)?64:ln(e)?4:Ft(e)?2:0;return on(e,t,n,r,a,l,o,!0)}function WN(e){return e?jE(e)||Df in e?sn({},e):e:null}function va(e,t,n=!1){const{props:r,ref:a,patchFlag:o,children:l}=e,u=t?wf(r||{},t):r,c={__v_isVNode:!0,__v_skip:!0,type:e.type,props:u,key:u&&YN(u),ref:t&&t.ref?n&&a?Rt(a)?a.concat(md(t)):[a,md(t)]:md(t):a,scopeId:e.scopeId,slotScopeIds:e.slotScopeIds,children:l,target:e.target,targetAnchor:e.targetAnchor,staticCount:e.staticCount,shapeFlag:e.shapeFlag,patchFlag:t&&e.type!==hr?o===-1?16:o|16:o,dynamicProps:e.dynamicProps,dynamicChildren:e.dynamicChildren,appContext:e.appContext,dirs:e.dirs,transition:e.transition,component:e.component,suspense:e.suspense,ssContent:e.ssContent&&va(e.ssContent),ssFallback:e.ssFallback&&va(e.ssFallback),el:e.el,anchor:e.anchor,ctx:e.ctx,ce:e.ce};return gN(c),c}function ql(e=" ",t=0){return En(js,null,e,t)}function ES(e,t){const n=En(Hs,null,e);return n.staticCount=t,n}function Ld(e="",t=!1){return t?(ki(),hS(Dr,null,e)):En(Dr,null,e)}function Pi(e){return e==null||typeof e=="boolean"?En(Dr):Rt(e)?En(hr,null,e.slice()):typeof e=="object"?$o(e):En(js,null,String(e))}function $o(e){return e.el===null&&e.patchFlag!==-1||e.memo?e:va(e)}function xf(e,t){let n=0;const{shapeFlag:r}=e;if(t==null)t=null;else if(Rt(t))n=16;else if(typeof t=="object")if(r&65){const a=t.default;a&&(a._c&&(a._d=!1),xf(e,a()),a._c&&(a._d=!0));return}else{n=32;const a=t._;!a&&!(Df in t)?t._ctx=Yn:a===3&&Yn&&(Yn.slots._===1?t._=1:(t._=2,e.patchFlag|=1024))}else Ft(t)?(t={default:t,_ctx:Yn},n=32):(t=String(t),r&64?(n=16,t=[ql(t)]):n=8);e.children=t,e.shapeFlag|=n}function wf(...e){const t={};for(let n=0;n<e.length;n++){const r=e[n];for(const a in r)if(a==="class")t.class!==r.class&&(t.class=Va([t.class,r.class]));else if(a==="style")t.style=tu([t.style,r.style]);else if(Co(a)){const o=t[a],l=r[a];l&&o!==l&&!(Rt(o)&&o.includes(l))&&(t[a]=o?[].concat(o,l):l)}else a!==""&&(t[a]=r[a])}return t}function Ei(e,t,n,r=null){Ti(e,t,7,[n,r])}const QG=NN();let jG=0;function SS(e,t,n){const r=e.type,a=(t?t.appContext:e.appContext)||QG,o={uid:jG++,vnode:e,type:r,parent:t,appContext:a,root:null,next:null,subTree:null,effect:null,update:null,scope:new zE(!0),render:null,proxy:null,exposed:null,exposeProxy:null,withProxy:null,provides:t?t.provides:Object.create(a.provides),accessCache:null,renderCache:[],components:null,directives:null,propsOptions:wN(r,a),emitsOptions:WR(r,a),emit:null,emitted:null,propsDefaults:yn,inheritAttrs:r.inheritAttrs,ctx:yn,data:yn,props:yn,attrs:yn,slots:yn,refs:yn,setupState:yn,setupContext:null,attrsProxy:null,slotsProxy:null,suspense:n,suspenseId:n?n.pendingId:0,asyncDep:null,asyncResolved:!1,isMounted:!1,isUnmounted:!1,isDeactivated:!1,bc:null,c:null,bm:null,m:null,bu:null,u:null,um:null,bum:null,da:null,a:null,rtg:null,rtc:null,ec:null,sp:null};return o.ctx={_:o},o.root=t?t.root:o,o.emit=g3.bind(null,o),e.ce&&e.ce(o),o}let Xn=null;const Aa=()=>Xn||Yn;let bS,Tl,FC="__VUE_INSTANCE_SETTERS__";(Tl=Lh()[FC])||(Tl=Lh()[FC]=[]),Tl.push(e=>Xn=e),bS=e=>{Tl.length>1?Tl.forEach(t=>t(e)):Tl[0](e)};const us=e=>{bS(e),e.scope.on()},ts=()=>{Xn&&Xn.scope.off(),bS(null)};function VN(e){return e.vnode.shapeFlag&4}let Yl=!1;function vS(e,t=!1){Yl=t;const{props:n,children:r}=e.vnode,a=VN(e);MG(e,n,a,t),FG(e,r);const o=a?XG(e,t):void 0;return Yl=!1,o}function XG(e,t){const n=e.type;e.accessCache=Object.create(null),e.proxy=XE(new Proxy(e.ctx,Gh));const{setup:r}=n;if(r){const a=e.setupContext=r.length>1?zN(e):null;us(e),nu();const o=Ya(r,e,0,[e.props,a]);if(ru(),ts(),gf(o)){if(o.then(ts,ts),t)return o.then(l=>{zh(e,l,t)}).catch(l=>{el(l,e,0)});e.asyncDep=o}else zh(e,o,t)}else TS(e,t)}function zh(e,t,n){Ft(t)?e.type.__ssrInlineRender?e.ssrRender=t:e.render=t:ln(t)&&(e.setupState=tS(t)),TS(e,n)}let Md,Kh;function ZG(e){Md=e,Kh=t=>{t.render._rc&&(t.withProxy=new Proxy(t.ctx,nG))}}const $h=()=>!Md;function TS(e,t,n){const r=e.type;if(H3(e),!e.render){if(!t&&Md&&!r.render){const a=e.vnode.props&&e.vnode.props["inline-template"]||r.template||Tc(e).template;if(a){const{isCustomElement:o,compilerOptions:l}=e.appContext.config,{delimiters:u,compilerOptions:c}=r,d=sn(sn({isCustomElement:o,delimiters:u},l),c);d.compatConfig=Object.create(rS),r.compatConfig&&sn(d.compatConfig,r.compatConfig),r.render=Md(a,d)}}e.render=r.render||vi,Kh&&Kh(e)}if(!n){us(e),nu();try{hG(e)}finally{ru(),ts()}}}function JG(e){return e.attrsProxy||(e.attrsProxy=new Proxy(e.attrs,{get(t,n){return ri(e,"get","$attrs"),t[n]}}))}function zN(e){const t=n=>{e.exposed=n||{}};return{get attrs(){return JG(e)},slots:e.slots,emit:e.emit,expose:t}}function Lf(e){if(e.exposed)return e.exposeProxy||(e.exposeProxy=new Proxy(tS(XE(e.exposed)),{get(t,n){if(n in t)return t[n];if(n in Ml)return Ml[n](e)},has(t,n){return n in t||n in Ml}}))}function Qh(e,t=!0){return Ft(e)?e.displayName||e.name:e.name||t&&e.__name}function eH(e){return Ft(e)&&"__vccOpts"in e}const KN=(e,t)=>r3(e,t,Yl);function $N(e,t,n){const r=arguments.length;return r===2?ln(t)&&!Rt(t)?Bi(t)?En(e,null,[t]):En(e,t):En(e,null,t):(r>3?n=Array.prototype.slice.call(arguments,2):r===3&&Bi(n)&&(n=[n]),En(e,t,n))}const QN=Symbol.for("v-scx"),jN=()=>Gs(QN);function tH(){}function nH(e,t,n,r){const a=n[r];if(a&&XN(a,e))return a;const o=t();return o.memo=e.slice(),n[r]=o}function XN(e,t){const n=e.memo;if(n.length!=t.length)return!1;for(let r=0;r<n.length;r++)if(os(n[r],t[r]))return!1;return Xs>0&&bi&&bi.push(e),!0}const ZN="3.3.8",rH={createComponentInstance:SS,setupComponent:vS,renderComponentRoot:pd,setCurrentRenderingInstance:ec,isVNode:Bi,normalizeVNode:Pi},iH=rH,aH=$R,oH={warnDeprecation:c3,createCompatVue:vG,isCompatEnabled:Sn,checkCompatEnabled:yf,softAssertCompatEnabled:yo},za=oH,sH="http://www.w3.org/2000/svg",Rs=typeof document<"u"?document:null,BC=Rs&&Rs.createElement("template"),lH={insert:(e,t,n)=>{t.insertBefore(e,n||null)},remove:e=>{const t=e.parentNode;t&&t.removeChild(e)},createElement:(e,t,n,r)=>{const a=t?Rs.createElementNS(sH,e):Rs.createElement(e,n?{is:n}:void 0);return e==="select"&&r&&r.multiple!=null&&a.setAttribute("multiple",r.multiple),a},createText:e=>Rs.createTextNode(e),createComment:e=>Rs.createComment(e),setText:(e,t)=>{e.nodeValue=t},setElementText:(e,t)=>{e.textContent=t},parentNode:e=>e.parentNode,nextSibling:e=>e.nextSibling,querySelector:e=>Rs.querySelector(e),setScopeId(e,t){e.setAttribute(t,"")},insertStaticContent(e,t,n,r,a,o){const l=n?n.previousSibling:t.lastChild;if(a&&(a===o||a.nextSibling))for(;t.insertBefore(a.cloneNode(!0),n),!(a===o||!(a=a.nextSibling)););else{BC.innerHTML=r?`<svg>${e}</svg>`:e;const u=BC.content;if(r){const c=u.firstChild;for(;c.firstChild;)u.appendChild(c.firstChild);u.removeChild(c)}t.insertBefore(u,n)}return[l?l.nextSibling:t.firstChild,n?n.previousSibling:t.lastChild]}},Vo="transition",Ru="animation",Wl=Symbol("_vtc"),yc=(e,{slots:t})=>$N(tN,eI(e),t);yc.displayName="Transition";yc.__isBuiltIn=!0;const JN={name:String,type:String,css:{type:Boolean,default:!0},duration:[String,Number,Object],enterFromClass:String,enterActiveClass:String,enterToClass:String,appearFromClass:String,appearActiveClass:String,appearToClass:String,leaveFromClass:String,leaveActiveClass:String,leaveToClass:String},uH=yc.props=sn({},fS,JN),Ts=(e,t=[])=>{Rt(e)?e.forEach(n=>n(...t)):e&&e(...t)},UC=e=>e?Rt(e)?e.some(t=>t.length>1):e.length>1:!1;function eI(e){const t={};for(const ne in e)ne in JN||(t[ne]=e[ne]);if(e.css===!1)return t;const{name:n="v",type:r,duration:a,enterFromClass:o=`${n}-enter-from`,enterActiveClass:l=`${n}-enter-active`,enterToClass:u=`${n}-enter-to`,appearFromClass:c=o,appearActiveClass:d=l,appearToClass:S=u,leaveFromClass:_=`${n}-leave-from`,leaveActiveClass:E=`${n}-leave-active`,leaveToClass:T=`${n}-leave-to`}=e,y=za.isCompatEnabled("TRANSITION_CLASSES",null);let M,v,A;if(y){const ne=te=>te.replace(/-from$/,"");e.enterFromClass||(M=ne(o)),e.appearFromClass||(v=ne(c)),e.leaveFromClass||(A=ne(_))}const O=cH(a),N=O&&O[0],R=O&&O[1],{onBeforeEnter:L,onEnter:I,onEnterCancelled:h,onLeave:k,onLeaveCancelled:F,onBeforeAppear:z=L,onAppear:K=I,onAppearCancelled:ue=h}=t,Z=(ne,te,G)=>{ka(ne,te?S:u),ka(ne,te?d:l),G&&G()},fe=(ne,te)=>{ne._isLeaving=!1,ka(ne,_),ka(ne,T),ka(ne,E),te&&te()},V=ne=>(te,G)=>{const se=ne?K:I,ve=()=>Z(te,ne,G);Ts(se,[te,ve]),GC(()=>{if(ka(te,ne?c:o),y){const Ge=ne?v:M;Ge&&ka(te,Ge)}na(te,ne?S:u),UC(se)||HC(te,r,N,ve)})};return sn(t,{onBeforeEnter(ne){Ts(L,[ne]),na(ne,o),y&&M&&na(ne,M),na(ne,l)},onBeforeAppear(ne){Ts(z,[ne]),na(ne,c),y&&v&&na(ne,v),na(ne,d)},onEnter:V(!1),onAppear:V(!0),onLeave(ne,te){ne._isLeaving=!0;const G=()=>fe(ne,te);na(ne,_),y&&A&&na(ne,A),nI(),na(ne,E),GC(()=>{!ne._isLeaving||(ka(ne,_),y&&A&&ka(ne,A),na(ne,T),UC(k)||HC(ne,r,R,G))}),Ts(k,[ne,G])},onEnterCancelled(ne){Z(ne,!1),Ts(h,[ne])},onAppearCancelled(ne){Z(ne,!0),Ts(ue,[ne])},onLeaveCancelled(ne){fe(ne),Ts(F,[ne])}})}function cH(e){if(e==null)return null;if(ln(e))return[sh(e.enter),sh(e.leave)];{const t=sh(e);return[t,t]}}function sh(e){return Od(e)}function na(e,t){t.split(/\s+/).forEach(n=>n&&e.classList.add(n)),(e[Wl]||(e[Wl]=new Set)).add(t)}function ka(e,t){t.split(/\s+/).forEach(r=>r&&e.classList.remove(r));const n=e[Wl];n&&(n.delete(t),n.size||(e[Wl]=void 0))}function GC(e){requestAnimationFrame(()=>{requestAnimationFrame(e)})}let dH=0;function HC(e,t,n,r){const a=e._endId=++dH,o=()=>{a===e._endId&&r()};if(n)return setTimeout(o,n);const{type:l,timeout:u,propCount:c}=tI(e,t);if(!l)return r();const d=l+"end";let S=0;const _=()=>{e.removeEventListener(d,E),o()},E=T=>{T.target===e&&++S>=c&&_()};setTimeout(()=>{S<c&&_()},u+1),e.addEventListener(d,E)}function tI(e,t){const n=window.getComputedStyle(e),r=y=>(n[y]||"").split(", "),a=r(`${Vo}Delay`),o=r(`${Vo}Duration`),l=qC(a,o),u=r(`${Ru}Delay`),c=r(`${Ru}Duration`),d=qC(u,c);let S=null,_=0,E=0;t===Vo?l>0&&(S=Vo,_=l,E=o.length):t===Ru?d>0&&(S=Ru,_=d,E=c.length):(_=Math.max(l,d),S=_>0?l>d?Vo:Ru:null,E=S?S===Vo?o.length:c.length:0);const T=S===Vo&&/\b(transform|all)(,|$)/.test(r(`${Vo}Property`).toString());return{type:S,timeout:_,propCount:E,hasTransform:T}}function qC(e,t){for(;e.length<t.length;)e=e.concat(e);return Math.max(...t.map((n,r)=>YC(n)+YC(e[r])))}function YC(e){return e==="auto"?0:Number(e.slice(0,-1).replace(",","."))*1e3}function nI(){return document.body.offsetHeight}function fH(e,t,n){const r=e[Wl];r&&(t=(t?[t,...r]:[...r]).join(" ")),t==null?e.removeAttribute("class"):n?e.setAttribute("class",t):e.className=t}const yS=Symbol("_vod"),CS={beforeMount(e,{value:t},{transition:n}){e[yS]=e.style.display==="none"?"":e.style.display,n&&t?n.beforeEnter(e):Nu(e,t)},mounted(e,{value:t},{transition:n}){n&&t&&n.enter(e)},updated(e,{value:t,oldValue:n},{transition:r}){!t!=!n&&(r?t?(r.beforeEnter(e),Nu(e,!0),r.enter(e)):r.leave(e,()=>{Nu(e,!1)}):Nu(e,t))},beforeUnmount(e,{value:t}){Nu(e,t)}};function Nu(e,t){e.style.display=t?e[yS]:"none"}function pH(){CS.getSSRProps=({value:e})=>{if(!e)return{style:{display:"none"}}}}function _H(e,t,n){const r=e.style,a=xn(n);if(n&&!a){if(t&&!xn(t))for(const o in t)n[o]==null&&jh(r,o,"");for(const o in n)jh(r,o,n[o])}else{const o=r.display;a?t!==n&&(r.cssText=n):t&&e.removeAttribute("style"),yS in e&&(r.display=o)}}const WC=/\s*!important$/;function jh(e,t,n){if(Rt(n))n.forEach(r=>jh(e,t,r));else if(n==null&&(n=""),t.startsWith("--"))e.setProperty(t,n);else{const r=mH(e,t);WC.test(n)?e.setProperty(ei(r),n.replace(WC,""),"important"):e[r]=n}}const VC=["Webkit","Moz","ms"],lh={};function mH(e,t){const n=lh[t];if(n)return n;let r=ni(t);if(r!=="filter"&&r in e)return lh[t]=r;r=gc(r);for(let a=0;a<VC.length;a++){const o=VC[a]+r;if(o in e)return lh[t]=o}return t}const zC="http://www.w3.org/1999/xlink";function gH(e,t,n,r,a){if(r&&t.startsWith("xlink:"))n==null?e.removeAttributeNS(zC,t.slice(6,t.length)):e.setAttributeNS(zC,t,n);else{if(EH(e,t,n,a))return;const o=SR(t);n==null||o&&!bR(n)?e.removeAttribute(t):e.setAttribute(t,o?"":n)}}const hH=Jl("contenteditable,draggable,spellcheck");function EH(e,t,n,r=null){if(hH(t)){const a=n===null?"false":typeof n!="boolean"&&n!==void 0?"true":null;if(a&&za.softAssertCompatEnabled("ATTR_ENUMERATED_COERCION",r,t,n,a))return e.setAttribute(t,a),!0}else if(n===!1&&!SR(t)&&za.softAssertCompatEnabled("ATTR_FALSE_VALUE",r,t))return e.removeAttribute(t),!0;return!1}function SH(e,t,n,r,a,o,l){if(t==="innerHTML"||t==="textContent"){r&&l(r,a,o),e[t]=n==null?"":n;return}const u=e.tagName;if(t==="value"&&u!=="PROGRESS"&&!u.includes("-")){e._value=n;const d=u==="OPTION"?e.getAttribute("value"):e.value,S=n==null?"":n;d!==S&&(e.value=S),n==null&&e.removeAttribute(t);return}let c=!1;if(n===""||n==null){const d=typeof e[t];d==="boolean"?n=bR(n):n==null&&d==="string"?(n="",c=!0):d==="number"&&(n=0,c=!0)}else if(n===!1&&za.isCompatEnabled("ATTR_FALSE_VALUE",a)){const d=typeof e[t];(d==="string"||d==="number")&&(n=d==="number"?0:"",c=!0)}try{e[t]=n}catch{}c&&e.removeAttribute(t)}function Eo(e,t,n,r){e.addEventListener(t,n,r)}function bH(e,t,n,r){e.removeEventListener(t,n,r)}const KC=Symbol("_vei");function vH(e,t,n,r,a=null){const o=e[KC]||(e[KC]={}),l=o[t];if(r&&l)l.value=r;else{const[u,c]=TH(t);if(r){const d=o[t]=AH(r,a);Eo(e,u,d,c)}else l&&(bH(e,u,l,c),o[t]=void 0)}}const $C=/(?:Once|Passive|Capture)$/;function TH(e){let t;if($C.test(e)){t={};let r;for(;r=e.match($C);)e=e.slice(0,e.length-r[0].length),t[r[0].toLowerCase()]=!0}return[e[2]===":"?e.slice(3):ei(e.slice(2)),t]}let uh=0;const yH=Promise.resolve(),CH=()=>uh||(yH.then(()=>uh=0),uh=Date.now());function AH(e,t){const n=r=>{if(!r._vts)r._vts=Date.now();else if(r._vts<=n.attached)return;Ti(OH(r,n.value),t,5,[r])};return n.value=e,n.attached=CH(),n}function OH(e,t){if(Rt(t)){const n=e.stopImmediatePropagation;return e.stopImmediatePropagation=()=>{n.call(e),e._stopped=!0},t.map(r=>a=>!a._stopped&&r&&r(a))}else return t}const QC=/^on[a-z]/,RH=(e,t,n,r,a=!1,o,l,u,c)=>{t==="class"?fH(e,r,a):t==="style"?_H(e,n,r):Co(t)?YE(t)||vH(e,t,n,r,l):(t[0]==="."?(t=t.slice(1),!0):t[0]==="^"?(t=t.slice(1),!1):NH(e,t,r,a))?SH(e,t,r,o,l,u,c):(t==="true-value"?e._trueValue=r:t==="false-value"&&(e._falseValue=r),gH(e,t,r,a,l))};function NH(e,t,n,r){return r?!!(t==="innerHTML"||t==="textContent"||t in e&&QC.test(t)&&Ft(n)):t==="spellcheck"||t==="draggable"||t==="translate"||t==="form"||t==="list"&&e.tagName==="INPUT"||t==="type"&&e.tagName==="TEXTAREA"||QC.test(t)&&xn(n)?!1:t in e}/*! #__NO_SIDE_EFFECTS__ */function rI(e,t){const n=pS(e);class r extends Mf{constructor(o){super(n,o,t)}}return r.def=n,r}/*! #__NO_SIDE_EFFECTS__ */const IH=e=>rI(e,pI),DH=typeof HTMLElement<"u"?HTMLElement:class{};class Mf extends DH{constructor(t,n={},r){super(),this._def=t,this._props=n,this._instance=null,this._connected=!1,this._resolved=!1,this._numberProps=null,this._ob=null,this.shadowRoot&&r?r(this._createVNode(),this.shadowRoot):(this.attachShadow({mode:"open"}),this._def.__asyncLoader||this._resolveProps(this._def))}connectedCallback(){this._connected=!0,this._instance||(this._resolved?this._update():this._resolveDef())}disconnectedCallback(){this._connected=!1,this._ob&&(this._ob.disconnect(),this._ob=null),Ec(()=>{this._connected||(Jh(null,this.shadowRoot),this._instance=null)})}_resolveDef(){this._resolved=!0;for(let r=0;r<this.attributes.length;r++)this._setAttr(this.attributes[r].name);this._ob=new MutationObserver(r=>{for(const a of r)this._setAttr(a.attributeName)}),this._ob.observe(this,{attributes:!0});const t=(r,a=!1)=>{const{props:o,styles:l}=r;let u;if(o&&!Rt(o))for(const c in o){const d=o[c];(d===Number||d&&d.type===Number)&&(c in this._props&&(this._props[c]=Od(this._props[c])),(u||(u=Object.create(null)))[ni(c)]=!0)}this._numberProps=u,a&&this._resolveProps(r),this._applyStyles(l),this._update()},n=this._def.__asyncLoader;n?n().then(r=>t(r,!0)):t(this._def)}_resolveProps(t){const{props:n}=t,r=Rt(n)?n:Object.keys(n||{});for(const a of Object.keys(this))a[0]!=="_"&&r.includes(a)&&this._setProp(a,this[a],!0,!1);for(const a of r.map(ni))Object.defineProperty(this,a,{get(){return this._getProp(a)},set(o){this._setProp(a,o)}})}_setAttr(t){let n=this.getAttribute(t);const r=ni(t);this._numberProps&&this._numberProps[r]&&(n=Od(n)),this._setProp(r,n,!1)}_getProp(t){return this._props[t]}_setProp(t,n,r=!0,a=!0){n!==this._props[t]&&(this._props[t]=n,a&&this._instance&&this._update(),r&&(n===!0?this.setAttribute(ei(t),""):typeof n=="string"||typeof n=="number"?this.setAttribute(ei(t),n+""):n||this.removeAttribute(ei(t))))}_update(){Jh(this._createVNode(),this.shadowRoot)}_createVNode(){const t=En(this._def,sn({},this._props));return this._instance||(t.ce=n=>{this._instance=n,n.isCE=!0;const r=(o,l)=>{this.dispatchEvent(new CustomEvent(o,{detail:l}))};n.emit=(o,...l)=>{r(o,l),ei(o)!==o&&r(ei(o),l)};let a=this;for(;a=a&&(a.parentNode||a.host);)if(a instanceof Mf){n.parent=a._instance,n.provides=a._instance.provides;break}}),t}_applyStyles(t){t&&t.forEach(n=>{const r=document.createElement("style");r.textContent=n,this.shadowRoot.appendChild(r)})}}function xH(e="$style"){{const t=Aa();if(!t)return yn;const n=t.type.__cssModules;if(!n)return yn;const r=n[e];return r||yn}}function wH(e){const t=Aa();if(!t)return;const n=t.ut=(a=e(t.proxy))=>{Array.from(document.querySelectorAll(`[data-v-owner="${t.uid}"]`)).forEach(o=>Zh(o,a))},r=()=>{const a=e(t.proxy);Xh(t.subTree,a),n(a)};XR(r),vc(()=>{const a=new MutationObserver(r);a.observe(t.subTree.el.parentNode,{childList:!0}),rc(()=>a.disconnect())})}function Xh(e,t){if(e.shapeFlag&128){const n=e.suspense;e=n.activeBranch,n.pendingBranch&&!n.isHydrating&&n.effects.push(()=>{Xh(n.activeBranch,t)})}for(;e.component;)e=e.component.subTree;if(e.shapeFlag&1&&e.el)Zh(e.el,t);else if(e.type===hr)e.children.forEach(n=>Xh(n,t));else if(e.type===Hs){let{el:n,anchor:r}=e;for(;n&&(Zh(n,t),n!==r);)n=n.nextSibling}}function Zh(e,t){if(e.nodeType===1){const n=e.style;for(const r in t)n.setProperty(`--${r}`,t[r])}}const iI=new WeakMap,aI=new WeakMap,kd=Symbol("_moveCb"),jC=Symbol("_enterCb"),AS={name:"TransitionGroup",props:sn({},uH,{tag:String,moveClass:String}),setup(e,{slots:t}){const n=Aa(),r=dS();let a,o;return If(()=>{if(!a.length)return;const l=e.moveClass||`${e.name||"v"}-move`;if(!FH(a[0].el,n.vnode.el,l))return;a.forEach(MH),a.forEach(kH);const u=a.filter(PH);nI(),u.forEach(c=>{const d=c.el,S=d.style;na(d,l),S.transform=S.webkitTransform=S.transitionDuration="";const _=d[kd]=E=>{E&&E.target!==d||(!E||/transform$/.test(E.propertyName))&&(d.removeEventListener("transitionend",_),d[kd]=null,ka(d,l))};d.addEventListener("transitionend",_)})}),()=>{const l=pn(e),u=eI(l);let c=l.tag||hr;!l.tag&&za.checkCompatEnabled("TRANSITION_GROUP_ROOT",n.parent)&&(c="span"),a=o,o=t.default?Rf(t.default()):[];for(let d=0;d<o.length;d++){const S=o[d];S.key!=null&&Qs(S,Hl(S,u,r,n))}if(a)for(let d=0;d<a.length;d++){const S=a[d];Qs(S,Hl(S,u,r,n)),iI.set(S,S.el.getBoundingClientRect())}return En(c,null,o)}}};AS.__isBuiltIn=!0;const LH=e=>delete e.mode;AS.props;const oI=AS;function MH(e){const t=e.el;t[kd]&&t[kd](),t[jC]&&t[jC]()}function kH(e){aI.set(e,e.el.getBoundingClientRect())}function PH(e){const t=iI.get(e),n=aI.get(e),r=t.left-n.left,a=t.top-n.top;if(r||a){const o=e.el.style;return o.transform=o.webkitTransform=`translate(${r}px,${a}px)`,o.transitionDuration="0s",e}}function FH(e,t,n){const r=e.cloneNode(),a=e[Wl];a&&a.forEach(u=>{u.split(/\s+/).forEach(c=>c&&r.classList.remove(c))}),n.split(/\s+/).forEach(u=>u&&r.classList.add(u)),r.style.display="none";const o=t.nodeType===1?t:t.parentNode;o.appendChild(r);const{hasTransform:l}=tI(r);return o.removeChild(r),l}const cs=e=>{const t=e.props["onUpdate:modelValue"]||e.props["onModelCompat:input"];return Rt(t)?n=>Jo(t,n):t};function BH(e){e.target.composing=!0}function XC(e){const t=e.target;t.composing&&(t.composing=!1,t.dispatchEvent(new Event("input")))}const ra=Symbol("_assign"),Pd={created(e,{modifiers:{lazy:t,trim:n,number:r}},a){e[ra]=cs(a);const o=r||a.props&&a.props.type==="number";Eo(e,t?"change":"input",l=>{if(l.target.composing)return;let u=e.value;n&&(u=u.trim()),o&&(u=Qu(u)),e[ra](u)}),n&&Eo(e,"change",()=>{e.value=e.value.trim()}),t||(Eo(e,"compositionstart",BH),Eo(e,"compositionend",XC),Eo(e,"change",XC))},mounted(e,{value:t}){e.value=t==null?"":t},beforeUpdate(e,{value:t,modifiers:{lazy:n,trim:r,number:a}},o){if(e[ra]=cs(o),e.composing||document.activeElement===e&&e.type!=="range"&&(n||r&&e.value.trim()===t||(a||e.type==="number")&&Qu(e.value)===t))return;const l=t==null?"":t;e.value!==l&&(e.value=l)}},OS={deep:!0,created(e,t,n){e[ra]=cs(n),Eo(e,"change",()=>{const r=e._modelValue,a=Vl(e),o=e.checked,l=e[ra];if(Rt(r)){const u=hc(r,a),c=u!==-1;if(o&&!c)l(r.concat(a));else if(!o&&c){const d=[...r];d.splice(u,1),l(d)}}else if(Js(r)){const u=new Set(r);o?u.add(a):u.delete(a),l(u)}else l(lI(e,o))})},mounted:ZC,beforeUpdate(e,t,n){e[ra]=cs(n),ZC(e,t,n)}};function ZC(e,{value:t,oldValue:n},r){e._modelValue=t,Rt(t)?e.checked=hc(t,r.props.value)>-1:Js(t)?e.checked=t.has(r.props.value):t!==n&&(e.checked=To(t,lI(e,!0)))}const RS={created(e,{value:t},n){e.checked=To(t,n.props.value),e[ra]=cs(n),Eo(e,"change",()=>{e[ra](Vl(e))})},beforeUpdate(e,{value:t,oldValue:n},r){e[ra]=cs(r),t!==n&&(e.checked=To(t,r.props.value))}},sI={deep:!0,created(e,{value:t,modifiers:{number:n}},r){const a=Js(t);Eo(e,"change",()=>{const o=Array.prototype.filter.call(e.options,l=>l.selected).map(l=>n?Qu(Vl(l)):Vl(l));e[ra](e.multiple?a?new Set(o):o:o[0])}),e[ra]=cs(r)},mounted(e,{value:t}){JC(e,t)},beforeUpdate(e,t,n){e[ra]=cs(n)},updated(e,{value:t}){JC(e,t)}};function JC(e,t){const n=e.multiple;if(!(n&&!Rt(t)&&!Js(t))){for(let r=0,a=e.options.length;r<a;r++){const o=e.options[r],l=Vl(o);if(n)Rt(t)?o.selected=hc(t,l)>-1:o.selected=t.has(l);else if(To(Vl(o),t)){e.selectedIndex!==r&&(e.selectedIndex=r);return}}!n&&e.selectedIndex!==-1&&(e.selectedIndex=-1)}}function Vl(e){return"_value"in e?e._value:e.value}function lI(e,t){const n=t?"_trueValue":"_falseValue";return n in e?e[n]:t}const NS={created(e,t,n){ud(e,t,n,null,"created")},mounted(e,t,n){ud(e,t,n,null,"mounted")},beforeUpdate(e,t,n,r){ud(e,t,n,r,"beforeUpdate")},updated(e,t,n,r){ud(e,t,n,r,"updated")}};function uI(e,t){switch(e){case"SELECT":return sI;case"TEXTAREA":return Pd;default:switch(t){case"checkbox":return OS;case"radio":return RS;default:return Pd}}}function ud(e,t,n,r,a){const l=uI(e.tagName,n.props&&n.props.type)[a];l&&l(e,t,n,r)}function UH(){Pd.getSSRProps=({value:e})=>({value:e}),RS.getSSRProps=({value:e},t)=>{if(t.props&&To(t.props.value,e))return{checked:!0}},OS.getSSRProps=({value:e},t)=>{if(Rt(e)){if(t.props&&hc(e,t.props.value)>-1)return{checked:!0}}else if(Js(e)){if(t.props&&e.has(t.props.value))return{checked:!0}}else if(e)return{checked:!0}},NS.getSSRProps=(e,t)=>{if(typeof t.type!="string")return;const n=uI(t.type.toUpperCase(),t.props&&t.props.type);if(n.getSSRProps)return n.getSSRProps(e,t)}}const GH=["ctrl","shift","alt","meta"],HH={stop:e=>e.stopPropagation(),prevent:e=>e.preventDefault(),self:e=>e.target!==e.currentTarget,ctrl:e=>!e.ctrlKey,shift:e=>!e.shiftKey,alt:e=>!e.altKey,meta:e=>!e.metaKey,left:e=>"button"in e&&e.button!==0,middle:e=>"button"in e&&e.button!==1,right:e=>"button"in e&&e.button!==2,exact:(e,t)=>GH.some(n=>e[`${n}Key`]&&!t.includes(n))},qH=(e,t)=>(n,...r)=>{for(let a=0;a<t.length;a++){const o=HH[t[a]];if(o&&o(n,t))return}return e(n,...r)},YH={esc:"escape",space:" ",up:"arrow-up",left:"arrow-left",right:"arrow-right",down:"arrow-down",delete:"backspace"},WH=(e,t)=>{let n,r=null;return r=Aa(),za.isCompatEnabled("CONFIG_KEY_CODES",r)&&r&&(n=r.appContext.config.keyCodes),a=>{if(!("key"in a))return;const o=ei(a.key);if(t.some(l=>l===o||YH[l]===o))return e(a);{const l=String(a.keyCode);if(za.isCompatEnabled("V_ON_KEYCODE_MODIFIER",r)&&t.some(u=>u==l))return e(a);if(n)for(const u of t){const c=n[u];if(c&&(Rt(c)?c.some(S=>String(S)===l):String(c)===l))return e(a)}}}},cI=sn({patchProp:RH},lH);let Bu,eA=!1;function dI(){return Bu||(Bu=PN(cI))}function fI(){return Bu=eA?Bu:FN(cI),eA=!0,Bu}const Jh=(...e)=>{dI().render(...e)},pI=(...e)=>{fI().hydrate(...e)},IS=(...e)=>{const t=dI().createApp(...e),{mount:n}=t;return t.mount=r=>{const a=_I(r);if(!a)return;const o=t._component;!Ft(o)&&!o.render&&!o.template&&(o.template=a.innerHTML),a.innerHTML="";const l=n(a,!1,a instanceof SVGElement);return a instanceof Element&&(a.removeAttribute("v-cloak"),a.setAttribute("data-v-app","")),l},t},VH=(...e)=>{const t=fI().createApp(...e),{mount:n}=t;return t.mount=r=>{const a=_I(r);if(a)return n(a,!0,a instanceof SVGElement)},t};function _I(e){return xn(e)?document.querySelector(e):e}let tA=!1;const zH=()=>{tA||(tA=!0,UH(),pH())};var KH=Object.freeze({__proto__:null,BaseTransition:tN,BaseTransitionPropsValidators:fS,Comment:Dr,EffectScope:zE,Fragment:hr,KeepAlive:iN,ReactiveEffect:Gl,Static:Hs,Suspense:N3,Teleport:WG,Text:js,Transition:yc,TransitionGroup:oI,VueElement:Mf,assertNumber:a3,callWithAsyncErrorHandling:Ti,callWithErrorHandling:Ya,camelize:ni,capitalize:gc,cloneVNode:va,compatUtils:za,computed:KN,createApp:IS,createBlock:hS,createCommentVNode:Ld,createElementBlock:Ma,createElementVNode:on,createHydrationRenderer:FN,createPropsRestProxy:mG,createRenderer:PN,createSSRApp:VH,createSlots:EN,createStaticVNode:ES,createTextVNode:ql,createVNode:En,customRef:XU,defineAsyncComponent:_d,defineComponent:pS,defineCustomElement:rI,defineEmits:iG,defineExpose:aG,defineModel:lG,defineOptions:oG,defineProps:rG,defineSSRCustomElement:IH,defineSlots:sG,get devtools(){return yl},effect:yU,effectScope:SU,getCurrentInstance:Aa,getCurrentScope:yR,getTransitionRawChildren:Rf,guardReactiveProps:WN,h:$N,handleError:el,hasInjectionContext:wG,hydrate:pI,initCustomFormatter:tH,initDirectivesForSSR:zH,inject:Gs,isMemoSame:XN,isProxy:jE,isReactive:So,isReadonly:$s,isRef:sr,isRuntimeOnly:$h,isShallow:ju,isVNode:Bi,markRaw:XE,mergeDefaults:pG,mergeModels:_G,mergeProps:wf,nextTick:Ec,normalizeClass:Va,normalizeProps:gU,normalizeStyle:tu,onActivated:aN,onBeforeMount:lN,onBeforeUnmount:nc,onBeforeUpdate:uN,onDeactivated:oN,onErrorCaptured:pN,onMounted:vc,onRenderTracked:fN,onRenderTriggered:dN,onScopeDispose:bU,onServerPrefetch:cN,onUnmounted:rc,onUpdated:If,openBlock:ki,popScopeId:E3,provide:IN,proxyRefs:tS,pushScopeId:h3,queuePostFlushCb:Id,reactive:ls,readonly:QE,ref:Dl,registerRuntimeCompiler:ZG,render:Jh,renderList:_S,renderSlot:SN,resolveComponent:O3,resolveDirective:KR,resolveDynamicComponent:zR,resolveFilter:aH,resolveTransitionHooks:Hl,setBlockTracking:Vh,setDevtoolsHook:qR,setTransitionHooks:Qs,shallowReactive:PR,shallowReadonly:WU,shallowRef:VU,ssrContextKey:QN,ssrUtils:iH,stop:CU,toDisplayString:Rd,toHandlerKey:Il,toHandlers:vN,toRaw:pn,toRef:t3,toRefs:ZU,toValue:$U,transformVNodeArgs:KG,triggerRef:KU,unref:eS,useAttrs:dG,useCssModule:xH,useCssVars:wH,useModel:fG,useSSRContext:jN,useSlots:cG,useTransitionState:dS,vModelCheckbox:OS,vModelDynamic:NS,vModelRadio:RS,vModelSelect:sI,vModelText:Pd,vShow:CS,version:ZN,warn:i3,watch:Ps,watchEffect:P3,watchPostEffect:XR,watchSyncEffect:F3,withAsyncContext:gG,withCtx:sS,withDefaults:uG,withDirectives:JR,withKeys:WH,withMemo:nH,withModifiers:qH,withScopeId:S3});function $H(...e){const t=IS(...e);return za.isCompatEnabled("RENDER_FUNCTION",null)&&(t.component("__compat__transition",yc),t.component("__compat__transition-group",oI),t.component("__compat__keep-alive",iN),t._context.directives.show=CS,t._context.directives.model=NS),t}function QH(){const e=za.createCompatVue(IS,$H);return sn(e,KH),e}const mI=QH();mI.compile=()=>{};var jH=mI;function XH(e){let t=0;for(let o=0;o<e.length;o++)t=e.charCodeAt(o)+((t<<5)-t),t=t&t;let n=(t%360+360)%360,r=(t%25+25)%25+75,a=(t%20+20)%20+40;return`hsl(${n}, ${r}%, ${a}%)`}function ZH(e,t){At(t).select(),document.execCommand("copy"),At(e.target).tooltip({title:"Copi\xE9!",trigger:"manual"}),At(e.target).tooltip("show"),setTimeout(function(){At(e.target).tooltip("hide")},1500)}const JH={htmlEntities:zA,colorHash:XH,copyToClipboard:ZH},eq={upload:(e,t,n,r=!1)=>{const a=window.CTFd;try{e instanceof At&&(form=form[0]);var e=new FormData(e);e.append("nonce",a.config.csrfNonce);for(let[c,d]of Object.entries(t))e.append(c,d)}catch{e.append("nonce",a.config.csrfNonce);for(let[c,d]of Object.entries(t))e.append(c,d)}var o=wu.ezProgressBar({width:0,title:"Progr\xE8s de l'envoi"}),l=r?"/api/v1/files/old?admin=true":"/api/v1/files?admin=true";console.log(r),At.ajax({url:a.config.urlRoot+l,data:e,type:"POST",cache:!1,contentType:!1,processData:!1,xhr:function(){var u=At.ajaxSettings.xhr();return u.upload.onprogress=function(c){if(c.lengthComputable){var d=c.loaded/c.total*100;o=wu.ezProgressBar({target:o,width:d})}},u},success:function(u){o=wu.ezProgressBar({target:o,width:100}),setTimeout(function(){o.modal("hide")},500),n&&n(u)}})}},tq={get_comments:e=>window.CTFd.fetch("/api/v1/comments?"+At.param(e),{method:"GET",credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"}}).then(function(n){return n.json()}),add_comment:(e,t,n,r)=>{const a=window.CTFd;let o={content:e,type:t,...n};a.fetch("/api/v1/comments",{method:"POST",credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"},body:JSON.stringify(o)}).then(function(l){return l.json()}).then(function(l){r&&r(l)})},delete_comment:e=>window.CTFd.fetch(`/api/v1/comments/${e}`,{method:"DELETE",credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"}}).then(function(n){return n.json()})},gI={files:eq,comments:tq,utils:JH,ezq:wu},nq=(e,t)=>{const n=e.__vccOpts||e;for(const[r,a]of t)n[r]=a;return n};function rq(){return Ys.fetch("/api/v1/files?type=page",{credentials:"same-origin"}).then(function(e){return e.json()})}const iq={props:{editor:Object},data:function(){return{files:[],selectedFile:null}},methods:{getPageFiles:function(){rq().then(e=>(this.files=e.data,this.files))},uploadChosenFiles:function(){let e=document.querySelector("#media-library-upload");gI.files.upload(e,{},t=>{this.getPageFiles()})},selectFile:function(e){return this.selectedFile=e,this.selectedFile},buildSelectedFileUrl:function(){return Ys.config.urlRoot+"/files/"+this.selectedFile.location},deleteSelectedFile:function(){var e=this.selectedFile.id;confirm("\xCAtes-vous certain de vouloir supprimer this file?")&&Ys.fetch("/api/v1/files/"+e,{method:"DELETE"}).then(t=>{t.status===200&&t.json().then(n=>{n.success&&(this.getPageFiles(),this.selectedFile=null)})})},insertSelectedFile:function(){let e=this.$props.editor;e.hasOwnProperty("codemirror")&&(e=e.codemirror);let t=e.getDoc(),n=t.getCursor(),r=this.buildSelectedFileUrl(),a=this.getIconClass(this.selectedFile.location)==="far fa-file-image",o=r.split("/").pop();link="[{0}]({1})".format(o,r),a&&(link="!"+link),t.replaceRange(link,n)},downloadSelectedFile:function(){var e=this.buildSelectedFileUrl();window.open(e,"_blank")},getIconClass:function(e){var t={png:"far fa-file-image",jpg:"far fa-file-image",jpeg:"far fa-file-image",gif:"far fa-file-image",bmp:"far fa-file-image",svg:"far fa-file-image",txt:"far fa-file-alt",mov:"far fa-file-video",mp4:"far fa-file-video",wmv:"far fa-file-video",flv:"far fa-file-video",mkv:"far fa-file-video",avi:"far fa-file-video",pdf:"far fa-file-pdf",mp3:"far fa-file-sound",wav:"far fa-file-sound",aac:"far fa-file-sound",zip:"far fa-file-archive",gz:"far fa-file-archive",tar:"far fa-file-archive","7z":"far fa-file-archive",rar:"far fa-file-archive",py:"far fa-file-code",c:"far fa-file-code",cpp:"far fa-file-code",html:"far fa-file-code",js:"far fa-file-code",rb:"far fa-file-code",go:"far fa-file-code"},n=e.split(".").pop();return t[n]||"far fa-file"}},created(){return this.getPageFiles()}},aq={id:"media-modal",class:"modal fade",tabindex:"-1"},oq={class:"modal-dialog modal-xl"},sq={class:"modal-content"},lq=ES('<div class="modal-header"><div class="container"><div class="row"><div class="col-md-12"><h3 class="text-center">Media Library</h3></div></div></div><button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">\xD7</span></button></div>',1),uq={class:"modal-body"},cq={class:"modal-header"},dq={class:"container"},fq={class:"row mh-100"},pq={class:"col-md-6",id:"media-library-list"},_q=["onClick"],mq={class:"media-item-title pl-1"},gq={class:"col-md-6",id:"media-library-details"},hq=on("h4",{class:"text-center"},"Media Details",-1),Eq={id:"media-item"},Sq={class:"text-center",id:"media-icon"},bq={key:0},vq={key:0},Tq=["src"],yq={key:1},Cq=on("br",null,null,-1),Aq={key:0,class:"text-center",id:"media-filename"},Oq=["href"],Rq=on("br",null,null,-1),Nq={class:"form-group"},Iq={key:0},Dq=["value"],xq={key:1},wq=on("input",{class:"form-control",type:"text",id:"media-link",readonly:""},null,-1),Lq={class:"form-group text-center"},Mq={class:"row"},kq={class:"col-md-6"},Pq={class:"col-md-3"},Fq=on("i",{class:"fas fa-download"},null,-1),Bq=[Fq],Uq={class:"col-md-3"},Gq=on("i",{class:"far fa-trash-alt"},null,-1),Hq=[Gq],qq=ES('<form id="media-library-upload" enctype="multipart/form-data"><div class="form-row pt-3"><div class="col"><div class="form-group"><label for="media-files">Upload Files</label><input type="file" name="file" id="media-files" class="form-control-file" multiple><sub class="help-block"> Attach multiple files using CTRL+Click or Cmd+Click. </sub></div></div><div class="col"><div class="form-group"><label>Upload File Location</label><input class="form-control" type="text" name="location" placeholder="Location"><sub class="help-block"> Route where file will be accessible (if not provided a random folder will be used). <br> Provide as <code>directory/filename.ext</code></sub></div></div></div><input type="hidden" value="page" name="type"></form>',1),Yq={class:"modal-footer"},Wq={class:"float-right"};function Vq(e,t,n,r,a,o){return ki(),Ma("div",aq,[on("div",oq,[on("div",sq,[lq,on("div",uq,[on("div",cq,[on("div",dq,[on("div",fq,[on("div",pq,[(ki(!0),Ma(hr,null,_S(e.files,l=>(ki(),Ma("div",{class:"media-item-wrapper",key:l.id},[on("a",{href:"javascript:void(0)",onClick:u=>{o.selectFile(l)}},[on("i",{class:Va(o.getIconClass(l.location)),"aria-hidden":"true"},null,2),on("small",mq,Rd(l.location.split("/").pop()),1)],8,_q)]))),128))]),on("div",gq,[hq,on("div",Eq,[on("div",Sq,[this.selectedFile?(ki(),Ma("div",bq,[o.getIconClass(this.selectedFile.location)==="far fa-file-image"?(ki(),Ma("div",vq,[on("img",{src:o.buildSelectedFileUrl(),style:{"max-width":"100%","max-height":"100%","object-fit":"contain"}},null,8,Tq)])):(ki(),Ma("div",yq,[on("i",{class:Va(`${o.getIconClass(this.selectedFile.location)} fa-4x`),"aria-hidden":"true"},null,2)]))])):Ld("",!0)]),Cq,this.selectedFile?(ki(),Ma("div",Aq,[on("a",{href:o.buildSelectedFileUrl(),target:"_blank"},Rd(this.selectedFile.location.split("/").pop()),9,Oq)])):Ld("",!0),Rq,on("div",Nq,[this.selectedFile?(ki(),Ma("div",Iq,[ql(" Link: "),on("input",{class:"form-control",type:"text",id:"media-link",value:o.buildSelectedFileUrl(),readonly:""},null,8,Dq)])):(ki(),Ma("div",xq,[ql(" Link: "),wq]))]),on("div",Lq,[on("div",Mq,[on("div",kq,[on("button",{onClick:t[0]||(t[0]=(...l)=>o.insertSelectedFile&&o.insertSelectedFile(...l)),class:"btn btn-success w-100",id:"media-insert","data-toggle":"tooltip","data-placement":"top",title:"Insert link into editor"}," Insert ")]),on("div",Pq,[on("button",{onClick:t[1]||(t[1]=(...l)=>o.downloadSelectedFile&&o.downloadSelectedFile(...l)),class:"btn btn-primary w-100",id:"media-download","data-toggle":"tooltip","data-placement":"top",title:"Download file"},Bq)]),on("div",Uq,[on("button",{onClick:t[2]||(t[2]=(...l)=>o.deleteSelectedFile&&o.deleteSelectedFile(...l)),class:"btn btn-danger w-100",id:"media-delete","data-toggle":"tooltip","data-placement":"top",title:"Delete file"},Hq)])])])])])])])]),qq]),on("div",Yq,[on("div",Wq,[on("button",{onClick:t[3]||(t[3]=(...l)=>o.uploadChosenFiles&&o.uploadChosenFiles(...l)),type:"submit",class:"btn btn-primary media-upload-button"}," Upload ")])])])])])}const zq=nq(iq,[["render",Vq]]);function Kq(e){const t=jH.extend(zq);let n=document.createElement("div");document.querySelector("main").appendChild(n);let r=new t({propsData:{editor:e}}).$mount(n);At("#media-modal").on("hidden.bs.modal",function(a){r.$destroy(),At("#media-modal").remove()}),At("#media-modal").modal()}function $q(e){if(Object.hasOwn(e,"mde")===!1){let t=new nU({autoDownloadFontAwesome:!1,toolbar:["bold","italic","heading","|","quote","unordered-list","ordered-list","|","link","image",{name:"media",action:n=>{Kq(n)},className:"fas fa-file-upload",title:"Media Library"},"|","preview","guide"],element:e,initialValue:At(e).val(),forceSync:!0,minHeight:"200px",renderingConfig:{codeSyntaxHighlighting:!0,hljs:qd}});e.mde=t,e.codemirror=t.codemirror,At(e).on("change keyup paste",function(){t.codemirror.getDoc().setValue(At(e).val()),t.codemirror.refresh()})}}function Qq(){At("textarea.markdown").each(function(e,t){$q(t)})}function jq(){At("th.sort-col").append(' <i class="fas fa-sort"></i>'),At("th.sort-col").click(function(){var n=At(this).parents("table").eq(0),r=n.find("tr:gt(0)").toArray().sort(e(At(this).index()));this.asc=!this.asc,this.asc||(r=r.reverse());for(var a=0;a<r.length;a++)n.append(r[a])});function e(n){return function(r,a){var o=t(r,n),l=t(a,n);return At.isNumeric(o)&&At.isNumeric(l)?o-l:o.toString().localeCompare(l)}}function t(n,r){return At(n).children("td").eq(r).text()}}const Xq=()=>{At(":input").each(function(){At(this).data("initial",At(this).val())}),At(function(){At("tr[data-href], td[data-href]").click(function(){var t=getSelection().toString();if(!t){var n=At(this).attr("data-href");n&&(window.location=n)}return!1}),At("[data-checkbox]").click(function(t){if(At(t.target).is("input[type=checkbox]")){t.stopImmediatePropagation();return}At(this).find("input[type=checkbox]").click(),t.stopImmediatePropagation()}),At("[data-checkbox-all]").on("click change",function(t){const n=At(this).prop("checked"),r=At(this).index()+1;At(this).closest("table").find(`tr td:nth-child(${r}) input[type=checkbox]`).prop("checked",n),t.stopImmediatePropagation()}),At("tr[data-href] a, tr[data-href] button").click(function(t){At(this).attr("data-dismiss")||t.stopPropagation()}),At(".page-select").change(function(){let t=new URL(window.location);t.searchParams.set("page",this.value),window.location.href=t.toString()}),At('a[data-toggle="tab"]').on("shown.bs.tab",function(t){sessionStorage.setItem("activeTab",At(t.target).attr("href"))});let e=sessionStorage.getItem("activeTab");if(e){let t=At(`.nav-tabs a[href="${e}"], .nav-pills a[href="${e}"]`);t.length?t.tab("show"):sessionStorage.removeItem("activeTab")}Qq(),jq(),At('[data-toggle="tooltip"]').tooltip(),document.querySelectorAll("pre code").forEach(t=>{qd.highlightBlock(t)})})};oc.extend(oR);Ys.init(window.init);window.CTFd=Ys;window.Alpine=AB;window.helpers=gI;window.$=At;window.dayjs=oc;window.nunjucks=OB;window.Howl=PE.Howl;At(()=>{Xq(),DB(),IB(Ys.config.urlRoot)});export{At as $,Qq as A,ph as B,Ys as C,VA as D,zl as E,hr as F,wA as G,Jr as H,oc as I,qd as J,oR as K,lF as L,Kq as M,XH as N,ID as O,uF as P,ZH as Q,oI as T,jH as V,nq as _,on as a,Ld as b,Ma as c,ES as d,O3 as e,En as f,sS as g,JR as h,OS as i,ql as j,E3 as k,Pd as l,WH as m,OB as n,ki as o,h3 as p,Va as q,_S as r,gI as s,Rd as t,sF as u,sI as v,qH as w,CS as x,$q as y,zA as z}; diff --git a/CTFd/themes/admin/static/assets/pages/notifications.35d02f62.js b/CTFd/themes/admin/static/assets/pages/notifications.9890ee16.js similarity index 97% rename from CTFd/themes/admin/static/assets/pages/notifications.35d02f62.js rename to CTFd/themes/admin/static/assets/pages/notifications.9890ee16.js index cbff97a7b6548fa3909c123ac4e151dab760ee65..ce81808735362ff2dea8f759710c3385e14ee73d 100644 --- a/CTFd/themes/admin/static/assets/pages/notifications.35d02f62.js +++ b/CTFd/themes/admin/static/assets/pages/notifications.9890ee16.js @@ -1 +1 @@ -import{_ as r,I as u,C as c,J as f,c as h,a as o,t as d,o as m,V as _,$ as n,B as p}from"./main.9b987665.js";const b={props:{id:Number,title:String,content:String,html:String,date:String},methods:{localDate:function(){return u(this.date).format("MMMM Do, h:mm:ss A")},deleteNotification:function(){confirm("\xCAtes-vous certain de vouloir supprimer this notification?")&&c.api.delete_notification({notificationId:this.id}).then(e=>{e.success&&(this.$destroy(),this.$el.parentNode.removeChild(this.$el))})}},mounted(){this.$el.querySelectorAll("pre code").forEach(e=>{f.highlightBlock(e)})}},v={class:"card bg-light mb-4"},g=["data-notif-id"],y=o("span",{"aria-hidden":"true"},"\xD7",-1),$=[y],k={class:"card-body"},N={class:"card-title"},S={class:"blockquote mb-0"},C=["innerHTML"],D={class:"text-muted"},M=["data-time"];function B(e,t,a,i,s,l){return m(),h("div",v,[o("button",{type:"button","data-notif-id":this.id,class:"delete-notification close position-absolute p-3",style:{right:"0"},"data-dismiss":"alert","aria-label":"Close",onClick:t[0]||(t[0]=V=>l.deleteNotification())},$,8,g),o("div",k,[o("h3",N,d(a.title),1),o("blockquote",S,[o("p",{innerHTML:this.html},null,8,C),o("small",D,[o("span",{"data-time":this.date},d(this.localDate()),9,M)])])])])}const x=r(b,[["render",B]]),E=_.extend(x);function I(e){e.preventDefault();const t=n(this),a=t.serializeJSON();t.find("button[type=submit]").attr("disabled",!0),c.api.post_notification_list({},a).then(i=>{t.find(":input[name=title]").val(""),t.find(":input[name=content]").val(""),setTimeout(function(){t.find("button[type=submit]").attr("disabled",!1)},1e3),i.success||p({title:"Erreur",body:"Impossible d'envoyer une notification. Veuillez r\xE9essayer.",button:"Ok"});let s=document.createElement("div");n("#notifications-list").prepend(s),new E({propsData:{id:i.data.id,title:i.data.title,content:i.data.content,html:i.data.html,date:i.data.date}}).$mount(s)})}function T(e){e.preventDefault();const t=n(this),a=t.data("notif-id");confirm("\xCAtes-vous certain de vouloir supprimer cette notification?")&&c.api.delete_notification({notificationId:a}).then(i=>{i.success&&t.parent().remove()})}n(()=>{n("#notifications_form").submit(I),n(".delete-notification").click(T)}); +import{_ as r,I as u,C as c,J as f,c as h,a as o,t as d,o as m,V as _,$ as n,B as p}from"./main.71d0edc5.js";const b={props:{id:Number,title:String,content:String,html:String,date:String},methods:{localDate:function(){return u(this.date).format("MMMM Do, h:mm:ss A")},deleteNotification:function(){confirm("\xCAtes-vous certain de vouloir supprimer this notification?")&&c.api.delete_notification({notificationId:this.id}).then(e=>{e.success&&(this.$destroy(),this.$el.parentNode.removeChild(this.$el))})}},mounted(){this.$el.querySelectorAll("pre code").forEach(e=>{f.highlightBlock(e)})}},v={class:"card bg-light mb-4"},g=["data-notif-id"],y=o("span",{"aria-hidden":"true"},"\xD7",-1),$=[y],k={class:"card-body"},N={class:"card-title"},S={class:"blockquote mb-0"},C=["innerHTML"],D={class:"text-muted"},M=["data-time"];function B(e,t,a,i,s,l){return m(),h("div",v,[o("button",{type:"button","data-notif-id":this.id,class:"delete-notification close position-absolute p-3",style:{right:"0"},"data-dismiss":"alert","aria-label":"Close",onClick:t[0]||(t[0]=V=>l.deleteNotification())},$,8,g),o("div",k,[o("h3",N,d(a.title),1),o("blockquote",S,[o("p",{innerHTML:this.html},null,8,C),o("small",D,[o("span",{"data-time":this.date},d(this.localDate()),9,M)])])])])}const x=r(b,[["render",B]]),E=_.extend(x);function I(e){e.preventDefault();const t=n(this),a=t.serializeJSON();t.find("button[type=submit]").attr("disabled",!0),c.api.post_notification_list({},a).then(i=>{t.find(":input[name=title]").val(""),t.find(":input[name=content]").val(""),setTimeout(function(){t.find("button[type=submit]").attr("disabled",!1)},1e3),i.success||p({title:"Erreur",body:"Impossible d'envoyer une notification. Veuillez r\xE9essayer.",button:"Ok"});let s=document.createElement("div");n("#notifications-list").prepend(s),new E({propsData:{id:i.data.id,title:i.data.title,content:i.data.content,html:i.data.html,date:i.data.date}}).$mount(s)})}function T(e){e.preventDefault();const t=n(this),a=t.data("notif-id");confirm("\xCAtes-vous certain de vouloir supprimer cette notification?")&&c.api.delete_notification({notificationId:a}).then(i=>{i.success&&t.parent().remove()})}n(()=>{n("#notifications_form").submit(I),n(".delete-notification").click(T)}); diff --git a/CTFd/themes/admin/static/assets/pages/pages.0091c1b7.js b/CTFd/themes/admin/static/assets/pages/pages.b065c23f.js similarity index 86% rename from CTFd/themes/admin/static/assets/pages/pages.0091c1b7.js rename to CTFd/themes/admin/static/assets/pages/pages.b065c23f.js index 3d1a9acc4fb680205d1d15c4c62505b0948849cb..ac298509fe1bed1bf63240f13bb927511c9b5482 100644 --- a/CTFd/themes/admin/static/assets/pages/pages.0091c1b7.js +++ b/CTFd/themes/admin/static/assets/pages/pages.b065c23f.js @@ -1 +1 @@ -import{$ as e,u as r,C as i}from"./main.9b987665.js";function n(p){let t=e("input[data-page-id]:checked").map(function(){return e(this).data("page-id")}),a=t.length===1?"page":"pages";r({title:"Supprimer Pages",body:`\xCAtes-vous certain de vouloir supprimer ${t.length} ${a}?`,success:function(){const s=[];for(var o of t)s.push(i.fetch(`/api/v1/pages/${o}`,{method:"DELETE"}));Promise.all(s).then(c=>{window.location.reload()})}})}e(()=>{e("#pages-delete-button").click(n)}); +import{$ as e,u as r,C as i}from"./main.71d0edc5.js";function n(p){let t=e("input[data-page-id]:checked").map(function(){return e(this).data("page-id")}),a=t.length===1?"page":"pages";r({title:"Supprimer Pages",body:`\xCAtes-vous certain de vouloir supprimer ${t.length} ${a}?`,success:function(){const s=[];for(var o of t)s.push(i.fetch(`/api/v1/pages/${o}`,{method:"DELETE"}));Promise.all(s).then(c=>{window.location.reload()})}})}e(()=>{e("#pages-delete-button").click(n)}); diff --git a/CTFd/themes/admin/static/assets/pages/reset.69d0f171.js b/CTFd/themes/admin/static/assets/pages/reset.07e67875.js similarity index 84% rename from CTFd/themes/admin/static/assets/pages/reset.69d0f171.js rename to CTFd/themes/admin/static/assets/pages/reset.07e67875.js index 21f08f3273225e3019c2f25dc9948a8b26a74f3a..4f56d79c01696b84883f0a1446b3da0cb8e5d0eb 100644 --- a/CTFd/themes/admin/static/assets/pages/reset.69d0f171.js +++ b/CTFd/themes/admin/static/assets/pages/reset.07e67875.js @@ -1 +1 @@ -import{$ as e,u as i}from"./main.9b987665.js";function s(t){t.preventDefault(),i({title:"R\xE9initialiser PolyScav?",body:"\xCAtes-vous s\xFBr de vouloir r\xE9initialiser votre \xE9v\xE8nement?",success:function(){e("#reset-ctf-form").off("submit").submit()}})}e(()=>{e("#reset-ctf-form").submit(s),e("#select-all").change(function(){const t=e(this).is(":checked");e("input[type='checkbox']").prop("checked",t)})}); +import{$ as e,u as i}from"./main.71d0edc5.js";function s(t){t.preventDefault(),i({title:"R\xE9initialiser PolyScav?",body:"\xCAtes-vous s\xFBr de vouloir r\xE9initialiser votre \xE9v\xE8nement?",success:function(){e("#reset-ctf-form").off("submit").submit()}})}e(()=>{e("#reset-ctf-form").submit(s),e("#select-all").change(function(){const t=e(this).is(":checked");e("input[type='checkbox']").prop("checked",t)})}); diff --git a/CTFd/themes/admin/static/assets/pages/scoreboard.47117ad7.js b/CTFd/themes/admin/static/assets/pages/scoreboard.1273237b.js similarity index 95% rename from CTFd/themes/admin/static/assets/pages/scoreboard.47117ad7.js rename to CTFd/themes/admin/static/assets/pages/scoreboard.1273237b.js index e475804b04fc1425407d7170918d696fe82b0910..579fed19708778c54b4de799d7418e22b1c2fcc3 100644 --- a/CTFd/themes/admin/static/assets/pages/scoreboard.47117ad7.js +++ b/CTFd/themes/admin/static/assets/pages/scoreboard.1273237b.js @@ -1,4 +1,4 @@ -import{$ as s,C as n,B as l}from"./main.9b987665.js";const d={users:(e,i)=>n.api.patch_user_public({userId:e},i),teams:(e,i)=>n.api.patch_team_public({teamId:e},i)};function u(){const e=s(this),i=e.data("account-id"),a=e.data("state");let t;a==="visible"?t=!0:a==="hidden"&&(t=!1);const o={hidden:t};d[n.config.userMode](i,o).then(c=>{c.success&&(t?(e.data("state","hidden"),e.addClass("btn-danger").removeClass("btn-success"),e.text("Hidden")):(e.data("state","visible"),e.addClass("btn-success").removeClass("btn-danger"),e.text("Visible")))})}function r(e,i){const a={hidden:i==="hidden"},t=[];for(let o of e.accounts)t.push(d[n.config.userMode](o,a));for(let o of e.users)t.push(d.users(o,a));Promise.all(t).then(o=>{window.location.reload()})}function b(e){let i=s(".tab-pane.active input[data-account-id]:checked").map(function(){return s(this).data("account-id")}),a=s(".tab-pane.active input[data-user-id]:checked").map(function(){return s(this).data("user-id")}),t={accounts:i,users:a};l({title:"Toggle Visibility",body:s(` +import{$ as s,C as n,B as l}from"./main.71d0edc5.js";const d={users:(e,i)=>n.api.patch_user_public({userId:e},i),teams:(e,i)=>n.api.patch_team_public({teamId:e},i)};function u(){const e=s(this),i=e.data("account-id"),a=e.data("state");let t;a==="visible"?t=!0:a==="hidden"&&(t=!1);const o={hidden:t};d[n.config.userMode](i,o).then(c=>{c.success&&(t?(e.data("state","hidden"),e.addClass("btn-danger").removeClass("btn-success"),e.text("Hidden")):(e.data("state","visible"),e.addClass("btn-success").removeClass("btn-danger"),e.text("Visible")))})}function r(e,i){const a={hidden:i==="hidden"},t=[];for(let o of e.accounts)t.push(d[n.config.userMode](o,a));for(let o of e.users)t.push(d.users(o,a));Promise.all(t).then(o=>{window.location.reload()})}function b(e){let i=s(".tab-pane.active input[data-account-id]:checked").map(function(){return s(this).data("account-id")}),a=s(".tab-pane.active input[data-user-id]:checked").map(function(){return s(this).data("user-id")}),t={accounts:i,users:a};l({title:"Toggle Visibility",body:s(` <form id="scoreboard-bulk-edit"> <div class="form-group"> <label>Visibility</label> diff --git a/CTFd/themes/admin/static/assets/pages/statistics.f0297493.js b/CTFd/themes/admin/static/assets/pages/statistics.7e5d4d77.js similarity index 97% rename from CTFd/themes/admin/static/assets/pages/statistics.f0297493.js rename to CTFd/themes/admin/static/assets/pages/statistics.7e5d4d77.js index fa193057a8110b77eeee9796e2d5d59e824390dc..1792e07582d02c6276172642a0590b504218ac75 100644 --- a/CTFd/themes/admin/static/assets/pages/statistics.f0297493.js +++ b/CTFd/themes/admin/static/assets/pages/statistics.7e5d4d77.js @@ -1 +1 @@ -import{$ as c,C as i,N as h}from"./main.9b987665.js";import{e as p}from"../echarts.common.e43059b8.js";const u={"#solves-graph":{data:()=>i.api.get_challenge_solve_statistics(),format:o=>{const t=o.data,r=[],a=[],s={};for(let n=0;n<t.length;n++)s[t[n].id]={name:t[n].name,solves:t[n].solves};const e=Object.keys(s).sort(function(n,l){return s[l].solves-s[n].solves});return c.each(e,function(n,l){r.push(s[l].name),a.push(s[l].solves)}),{title:{left:"center",text:"Solve Counts"},tooltip:{trigger:"item"},toolbox:{show:!0,feature:{mark:{show:!0},dataView:{show:!0,readOnly:!1},magicType:{show:!0,type:["line","bar"]},restore:{show:!0},saveAsImage:{show:!0}}},xAxis:{name:"Solve Count",nameLocation:"middle",type:"value"},yAxis:{name:"Challenge Name",nameLocation:"middle",nameGap:60,type:"category",data:r,axisLabel:{interval:0,rotate:0}},dataZoom:[{show:!1,start:0,end:100},{type:"inside",yAxisIndex:0,show:!0,width:20},{fillerColor:"rgba(233, 236, 241, 0.4)",show:!0,yAxisIndex:0,width:20}],series:[{itemStyle:{normal:{color:"#1f76b4"}},data:a,type:"bar"}]}}},"#keys-pie-graph":{data:()=>i.api.get_submission_property_counts({column:"type"}),format:o=>{const t=o.data,r=t.correct,a=t.incorrect;return{title:{left:"center",text:"Pourcentage de soumission"},tooltip:{trigger:"item"},toolbox:{show:!0,feature:{dataView:{show:!0,readOnly:!1},saveAsImage:{}}},legend:{orient:"vertical",top:"middle",right:0,data:["Fails","Solves"]},series:[{name:"Pourcentage de soumission",type:"pie",radius:["30%","50%"],avoidLabelOverlap:!1,label:{show:!1,position:"center"},itemStyle:{normal:{label:{show:!0,formatter:function(e){return`${e.name} - ${e.value} (${e.percent}%)`}},labelLine:{show:!0}},emphasis:{label:{show:!0,position:"center",textStyle:{fontSize:"14",fontWeight:"normal"}}}},emphasis:{label:{show:!0,fontSize:"30",fontWeight:"bold"}},labelLine:{show:!1},data:[{value:a,name:"Fails",itemStyle:{color:"rgb(207, 38, 0)"}},{value:r,name:"Solves",itemStyle:{color:"rgb(0, 209, 64)"}}]}]}}},"#categories-pie-graph":{data:()=>i.api.get_challenge_property_counts({column:"category"}),format:o=>{const t=o.data,r=[],a=[];for(let e in t)Object.hasOwn(t,e)&&(r.push(e),a.push(t[e]));for(let e=0;e<t.length;e++)r.push(t[e].category),a.push(t[e].count);let s={title:{left:"center",text:"R\xE9partition des cat\xE9gories"},tooltip:{trigger:"item"},toolbox:{show:!0,feature:{dataView:{show:!0,readOnly:!1},saveAsImage:{}}},legend:{type:"scroll",orient:"vertical",top:"middle",right:10,data:[]},series:[{name:"R\xE9partition des cat\xE9gories",type:"pie",radius:["30%","50%"],label:{show:!1,position:"center"},itemStyle:{normal:{label:{show:!0,formatter:function(e){return`${e.percent}% (${e.value})`}},labelLine:{show:!0}},emphasis:{label:{show:!0,position:"center",textStyle:{fontSize:"14",fontWeight:"normal"}}}},emphasis:{label:{show:!0,fontSize:"30",fontWeight:"bold"}},data:[]}]};return r.forEach((e,d)=>{s.legend.data.push(e),s.series[0].data.push({value:a[d],name:e,itemStyle:{color:h(e)}})}),s}},"#solve-percentages-graph":{layout:o=>({title:"Pourcentage de r\xE9solution par d\xE9fi",xaxis:{title:"Nom du d\xE9fi"},yaxis:{title:`Pourcentage de ${i.config.userMode.charAt(0).toUpperCase()+i.config.userMode.slice(1)} (%)`,range:[0,100]},annotations:o}),data:()=>i.api.get_challenge_solve_percentages(),format:o=>{const t=o.data,r=[],a=[];for(let e in t)r.push(t[e].name),a.push(t[e].percentage*100),t[e].name,t[e].percentage*100,Math.round(t[e].percentage*100)+"";return{title:{left:"center",text:"Pourcentage de r\xE9solution par d\xE9fi"},tooltip:{trigger:"item",formatter:function(e){return`${e.name} - ${(Math.round(e.value*10)/10).toFixed(1)}%`}},toolbox:{show:!0,feature:{mark:{show:!0},dataView:{show:!0,readOnly:!1},magicType:{show:!0,type:["line","bar"]},restore:{show:!0},saveAsImage:{show:!0}}},xAxis:{name:"Nom du d\xE9fi",nameGap:40,nameLocation:"middle",type:"category",data:r,axisLabel:{interval:0,rotate:50}},yAxis:{name:`"Pourcentage de ${i.config.userMode.charAt(0).toUpperCase()+i.config.userMode.slice(1)} (%)`,nameGap:50,nameLocation:"middle",type:"value",min:0,max:100},dataZoom:[{show:!1,start:0,end:100},{type:"inside",show:!0,start:0,end:100},{fillerColor:"rgba(233, 236, 241, 0.4)",show:!0,right:60,yAxisIndex:0,width:20},{type:"slider",fillerColor:"rgba(233, 236, 241, 0.4)",top:35,height:20,show:!0,start:0,end:100}],series:[{itemStyle:{normal:{color:"#1f76b4"}},data:a,type:"bar"}]}}},"#score-distribution-graph":{layout:o=>({title:"Distribution de score",xaxis:{title:"Cat\xE9gorie de score",showticklabels:!0,type:"category"},yaxis:{title:`Number of ${i.config.userMode.charAt(0).toUpperCase()+i.config.userMode.slice(1)}`},annotations:o}),data:()=>i.fetch("/api/v1/statistics/scores/distribution").then(function(o){return o.json()}),format:o=>{const t=o.data.brackets,r=[],a=[],s=[];for(let n in t)r.push(parseInt(n));r.sort((n,l)=>n-l);let e="<0";return r.map(n=>{a.push(`${e} - ${n}`),s.push(t[n]),e=n}),{title:{left:"center",text:"Distribution de score"},tooltip:{trigger:"item"},toolbox:{show:!0,feature:{mark:{show:!0},dataView:{show:!0,readOnly:!1},magicType:{show:!0,type:["line","bar"]},restore:{show:!0},saveAsImage:{show:!0}}},xAxis:{name:"Cat\xE9gorie de score",nameGap:40,nameLocation:"middle",type:"category",data:a},yAxis:{name:`Nombre de ${i.config.userMode.charAt(0).toUpperCase()+i.config.userMode.slice(1)}`,nameGap:50,nameLocation:"middle",type:"value"},dataZoom:[{show:!1,start:0,end:100},{type:"inside",show:!0,start:0,end:100},{fillerColor:"rgba(233, 236, 241, 0.4)",show:!0,right:60,yAxisIndex:0,width:20},{type:"slider",fillerColor:"rgba(233, 236, 241, 0.4)",top:35,height:20,show:!0,start:0,end:100}],series:[{itemStyle:{normal:{color:"#1f76b4"}},data:s,type:"bar"}]}}}},m=()=>{for(let o in u){const t=u[o];c(o).empty();let a=p.init(document.querySelector(o));t.data().then(t.format).then(s=>{a.setOption(s),c(window).on("resize",function(){a!=null&&a!=null&&a.resize()})})}};function f(){for(let o in u){const t=u[o];let r=p.init(document.querySelector(o));t.data().then(t.format).then(a=>{r.setOption(a)})}}c(()=>{m(),setInterval(f,3e5)}); +import{$ as c,C as i,N as h}from"./main.71d0edc5.js";import{e as p}from"../echarts.common.a0aaa3a0.js";const u={"#solves-graph":{data:()=>i.api.get_challenge_solve_statistics(),format:o=>{const t=o.data,r=[],a=[],s={};for(let n=0;n<t.length;n++)s[t[n].id]={name:t[n].name,solves:t[n].solves};const e=Object.keys(s).sort(function(n,l){return s[l].solves-s[n].solves});return c.each(e,function(n,l){r.push(s[l].name),a.push(s[l].solves)}),{title:{left:"center",text:"Solve Counts"},tooltip:{trigger:"item"},toolbox:{show:!0,feature:{mark:{show:!0},dataView:{show:!0,readOnly:!1},magicType:{show:!0,type:["line","bar"]},restore:{show:!0},saveAsImage:{show:!0}}},xAxis:{name:"Solve Count",nameLocation:"middle",type:"value"},yAxis:{name:"Challenge Name",nameLocation:"middle",nameGap:60,type:"category",data:r,axisLabel:{interval:0,rotate:0}},dataZoom:[{show:!1,start:0,end:100},{type:"inside",yAxisIndex:0,show:!0,width:20},{fillerColor:"rgba(233, 236, 241, 0.4)",show:!0,yAxisIndex:0,width:20}],series:[{itemStyle:{normal:{color:"#1f76b4"}},data:a,type:"bar"}]}}},"#keys-pie-graph":{data:()=>i.api.get_submission_property_counts({column:"type"}),format:o=>{const t=o.data,r=t.correct,a=t.incorrect;return{title:{left:"center",text:"Pourcentage de soumission"},tooltip:{trigger:"item"},toolbox:{show:!0,feature:{dataView:{show:!0,readOnly:!1},saveAsImage:{}}},legend:{orient:"vertical",top:"middle",right:0,data:["Fails","Solves"]},series:[{name:"Pourcentage de soumission",type:"pie",radius:["30%","50%"],avoidLabelOverlap:!1,label:{show:!1,position:"center"},itemStyle:{normal:{label:{show:!0,formatter:function(e){return`${e.name} - ${e.value} (${e.percent}%)`}},labelLine:{show:!0}},emphasis:{label:{show:!0,position:"center",textStyle:{fontSize:"14",fontWeight:"normal"}}}},emphasis:{label:{show:!0,fontSize:"30",fontWeight:"bold"}},labelLine:{show:!1},data:[{value:a,name:"Fails",itemStyle:{color:"rgb(207, 38, 0)"}},{value:r,name:"Solves",itemStyle:{color:"rgb(0, 209, 64)"}}]}]}}},"#categories-pie-graph":{data:()=>i.api.get_challenge_property_counts({column:"category"}),format:o=>{const t=o.data,r=[],a=[];for(let e in t)Object.hasOwn(t,e)&&(r.push(e),a.push(t[e]));for(let e=0;e<t.length;e++)r.push(t[e].category),a.push(t[e].count);let s={title:{left:"center",text:"R\xE9partition des cat\xE9gories"},tooltip:{trigger:"item"},toolbox:{show:!0,feature:{dataView:{show:!0,readOnly:!1},saveAsImage:{}}},legend:{type:"scroll",orient:"vertical",top:"middle",right:10,data:[]},series:[{name:"R\xE9partition des cat\xE9gories",type:"pie",radius:["30%","50%"],label:{show:!1,position:"center"},itemStyle:{normal:{label:{show:!0,formatter:function(e){return`${e.percent}% (${e.value})`}},labelLine:{show:!0}},emphasis:{label:{show:!0,position:"center",textStyle:{fontSize:"14",fontWeight:"normal"}}}},emphasis:{label:{show:!0,fontSize:"30",fontWeight:"bold"}},data:[]}]};return r.forEach((e,d)=>{s.legend.data.push(e),s.series[0].data.push({value:a[d],name:e,itemStyle:{color:h(e)}})}),s}},"#solve-percentages-graph":{layout:o=>({title:"Pourcentage de r\xE9solution par d\xE9fi",xaxis:{title:"Nom du d\xE9fi"},yaxis:{title:`Pourcentage de ${i.config.userMode.charAt(0).toUpperCase()+i.config.userMode.slice(1)} (%)`,range:[0,100]},annotations:o}),data:()=>i.api.get_challenge_solve_percentages(),format:o=>{const t=o.data,r=[],a=[];for(let e in t)r.push(t[e].name),a.push(t[e].percentage*100),t[e].name,t[e].percentage*100,Math.round(t[e].percentage*100)+"";return{title:{left:"center",text:"Pourcentage de r\xE9solution par d\xE9fi"},tooltip:{trigger:"item",formatter:function(e){return`${e.name} - ${(Math.round(e.value*10)/10).toFixed(1)}%`}},toolbox:{show:!0,feature:{mark:{show:!0},dataView:{show:!0,readOnly:!1},magicType:{show:!0,type:["line","bar"]},restore:{show:!0},saveAsImage:{show:!0}}},xAxis:{name:"Nom du d\xE9fi",nameGap:40,nameLocation:"middle",type:"category",data:r,axisLabel:{interval:0,rotate:50}},yAxis:{name:`"Pourcentage de ${i.config.userMode.charAt(0).toUpperCase()+i.config.userMode.slice(1)} (%)`,nameGap:50,nameLocation:"middle",type:"value",min:0,max:100},dataZoom:[{show:!1,start:0,end:100},{type:"inside",show:!0,start:0,end:100},{fillerColor:"rgba(233, 236, 241, 0.4)",show:!0,right:60,yAxisIndex:0,width:20},{type:"slider",fillerColor:"rgba(233, 236, 241, 0.4)",top:35,height:20,show:!0,start:0,end:100}],series:[{itemStyle:{normal:{color:"#1f76b4"}},data:a,type:"bar"}]}}},"#score-distribution-graph":{layout:o=>({title:"Distribution de score",xaxis:{title:"Cat\xE9gorie de score",showticklabels:!0,type:"category"},yaxis:{title:`Number of ${i.config.userMode.charAt(0).toUpperCase()+i.config.userMode.slice(1)}`},annotations:o}),data:()=>i.fetch("/api/v1/statistics/scores/distribution").then(function(o){return o.json()}),format:o=>{const t=o.data.brackets,r=[],a=[],s=[];for(let n in t)r.push(parseInt(n));r.sort((n,l)=>n-l);let e="<0";return r.map(n=>{a.push(`${e} - ${n}`),s.push(t[n]),e=n}),{title:{left:"center",text:"Distribution de score"},tooltip:{trigger:"item"},toolbox:{show:!0,feature:{mark:{show:!0},dataView:{show:!0,readOnly:!1},magicType:{show:!0,type:["line","bar"]},restore:{show:!0},saveAsImage:{show:!0}}},xAxis:{name:"Cat\xE9gorie de score",nameGap:40,nameLocation:"middle",type:"category",data:a},yAxis:{name:`Nombre de ${i.config.userMode.charAt(0).toUpperCase()+i.config.userMode.slice(1)}`,nameGap:50,nameLocation:"middle",type:"value"},dataZoom:[{show:!1,start:0,end:100},{type:"inside",show:!0,start:0,end:100},{fillerColor:"rgba(233, 236, 241, 0.4)",show:!0,right:60,yAxisIndex:0,width:20},{type:"slider",fillerColor:"rgba(233, 236, 241, 0.4)",top:35,height:20,show:!0,start:0,end:100}],series:[{itemStyle:{normal:{color:"#1f76b4"}},data:s,type:"bar"}]}}}},m=()=>{for(let o in u){const t=u[o];c(o).empty();let a=p.init(document.querySelector(o));t.data().then(t.format).then(s=>{a.setOption(s),c(window).on("resize",function(){a!=null&&a!=null&&a.resize()})})}};function f(){for(let o in u){const t=u[o];let r=p.init(document.querySelector(o));t.data().then(t.format).then(a=>{r.setOption(a)})}}c(()=>{m(),setInterval(f,3e5)}); diff --git a/CTFd/themes/admin/static/assets/pages/submissions.32ae0189.js b/CTFd/themes/admin/static/assets/pages/submissions.2a80c1be.js similarity index 96% rename from CTFd/themes/admin/static/assets/pages/submissions.32ae0189.js rename to CTFd/themes/admin/static/assets/pages/submissions.2a80c1be.js index 9c9b039f1947fe03016235150d8ebb8571db887b..dfd27c38706fb1e9ec968f81d98d1747e9c96946 100644 --- a/CTFd/themes/admin/static/assets/pages/submissions.32ae0189.js +++ b/CTFd/themes/admin/static/assets/pages/submissions.2a80c1be.js @@ -1 +1 @@ -import{$ as e,u as c,z as u,C as l,B as p}from"./main.9b987665.js";import{s as f}from"../visual.9f12da04.js";window.carouselPosition=0;window.carouselMax=0;function h(i){const t=e(this).data("submission-id"),o=e(this).parent().parent(),s=o.find(".chal").text().trim(),n=o.find(".team").text().trim(),a=e(this).parent().parent();c({title:"Supprimer soumission",body:"\xCAtes-vous certain de vouloir supprimer la soumission de l'\xE9quipe {0} pour le d\xE9fi {1}".format("<strong>"+u(n)+"</strong>","<strong>"+u(s)+"</strong>"),success:function(){alert({submissionId:t}),l.api.delete_submission({submissionId:t}).then(function(r){r.success&&a.remove()})}})}function g(i){let t=e("input[data-submission-id]:checked").map(function(){return e(this).data("submission-id")}),o=t.length===1?"submission":"submissions";c({title:"Supprimer une soumission",body:`\xCAtes-vous certain de vouloir supprimer ${t.length} ${o}?`,success:function(){const s=[];for(var n of t)s.push(l.api.delete_submission({submissionId:n}));Promise.all(s).then(a=>{window.location.reload()})}})}function b(i){let t=e("input[data-submission-id]:checked").map(function(){return e(this).data("submission-id")}).get(),o=t.length===1?"submission":"submissions",s=[];c({title:"Valider une soumission",body:`\xCAtes-vous s\xFBr de vouloir marquer ${t.length} ${o} correct?`,success:function(){const n=t.map(a=>l.fetch(`/api/v1/submissions/${a}`,{method:"GET",credentials:"same-origin",headers:{Accept:"application/json"}}).then(r=>r.json()).then(r=>{r.data.provided!=="M\xE9dia en traitement"?s.push(a):p({title:"Erreur",body:`Soumission ID ${a} ne peut \xEAtre marqu\xE9e comme correcte car le media est encore en traitement.`,button:"OK"})}));Promise.all(n).then(()=>{if(s.length>0){const a=s.map(r=>l.fetch(`/api/v1/submissions/${r}`,{method:"PATCH",credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"},body:JSON.stringify({type:"correct"})}));Promise.all(a).then(()=>{window.location.reload()})}})}})}function m(i){const t=new URLSearchParams(window.location.search);t.has("full")?t.delete("full"):t.set("full","true"),window.location.href=`${window.location.pathname}?${t.toString()}`}function w(i){let t=e(i.currentTarget),o=t.find("i"),s=t.parent().find("pre");s.hasClass("full-flag")?(s.text(s.attr("title").substring(0,42)+"..."),s.removeClass("full-flag"),o.addClass("fa-eye"),o.removeClass("fa-eye-slash")):(s.text(s.attr("title")),s.addClass("full-flag"),o.addClass("fa-eye-slash"),o.removeClass("fa-eye"))}function v(i){let s=e(i.currentTarget).parent().find("pre").attr("title");navigator.clipboard.writeText(s),e(i.currentTarget).tooltip({title:"Copi\xE9!",trigger:"manual"}),e(i.currentTarget).tooltip("show"),setTimeout(function(){e(i.currentTarget).tooltip("hide")},1500)}function y(i){const o=e(i.target).closest("[data-submission-id]").data("submission-id");if(!o){alert("Submission ID is not defined.");return}const s=e(i.target).text(),n=prompt("Enter the new value for the submission:",s);n!==null&&n.trim()!==""?l.fetch(`/api/v1/submissions/${o}`,{method:"PATCH",credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"},body:JSON.stringify({value:n.trim()})}).then(window.location.reload()):alert("Invalid input. Update canceled.")}e(()=>{e("#show-full-flags-button").click(m),e("#show-short-flags-button").click(m),e(".show-flag").click(w),e(".copy-flag").click(v),e("#correct-flags-button").click(b),e(".delete-correct-submission").click(h),e("#submission-delete-button").click(g),e(".submission-value").click(y)});let d=document.getElementsByClassName("imageContainer");for(let i=0;i<d.length;i++)f(d[i]); +import{$ as e,u as c,z as u,C as l,B as p}from"./main.71d0edc5.js";import{s as f}from"../visual.0867334a.js";window.carouselPosition=0;window.carouselMax=0;function h(i){const t=e(this).data("submission-id"),o=e(this).parent().parent(),s=o.find(".chal").text().trim(),n=o.find(".team").text().trim(),a=e(this).parent().parent();c({title:"Supprimer soumission",body:"\xCAtes-vous certain de vouloir supprimer la soumission de l'\xE9quipe {0} pour le d\xE9fi {1}".format("<strong>"+u(n)+"</strong>","<strong>"+u(s)+"</strong>"),success:function(){alert({submissionId:t}),l.api.delete_submission({submissionId:t}).then(function(r){r.success&&a.remove()})}})}function g(i){let t=e("input[data-submission-id]:checked").map(function(){return e(this).data("submission-id")}),o=t.length===1?"submission":"submissions";c({title:"Supprimer une soumission",body:`\xCAtes-vous certain de vouloir supprimer ${t.length} ${o}?`,success:function(){const s=[];for(var n of t)s.push(l.api.delete_submission({submissionId:n}));Promise.all(s).then(a=>{window.location.reload()})}})}function b(i){let t=e("input[data-submission-id]:checked").map(function(){return e(this).data("submission-id")}).get(),o=t.length===1?"submission":"submissions",s=[];c({title:"Valider une soumission",body:`\xCAtes-vous s\xFBr de vouloir marquer ${t.length} ${o} correct?`,success:function(){const n=t.map(a=>l.fetch(`/api/v1/submissions/${a}`,{method:"GET",credentials:"same-origin",headers:{Accept:"application/json"}}).then(r=>r.json()).then(r=>{r.data.provided!=="M\xE9dia en traitement"?s.push(a):p({title:"Erreur",body:`Soumission ID ${a} ne peut \xEAtre marqu\xE9e comme correcte car le media est encore en traitement.`,button:"OK"})}));Promise.all(n).then(()=>{if(s.length>0){const a=s.map(r=>l.fetch(`/api/v1/submissions/${r}`,{method:"PATCH",credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"},body:JSON.stringify({type:"correct"})}));Promise.all(a).then(()=>{window.location.reload()})}})}})}function m(i){const t=new URLSearchParams(window.location.search);t.has("full")?t.delete("full"):t.set("full","true"),window.location.href=`${window.location.pathname}?${t.toString()}`}function w(i){let t=e(i.currentTarget),o=t.find("i"),s=t.parent().find("pre");s.hasClass("full-flag")?(s.text(s.attr("title").substring(0,42)+"..."),s.removeClass("full-flag"),o.addClass("fa-eye"),o.removeClass("fa-eye-slash")):(s.text(s.attr("title")),s.addClass("full-flag"),o.addClass("fa-eye-slash"),o.removeClass("fa-eye"))}function v(i){let s=e(i.currentTarget).parent().find("pre").attr("title");navigator.clipboard.writeText(s),e(i.currentTarget).tooltip({title:"Copi\xE9!",trigger:"manual"}),e(i.currentTarget).tooltip("show"),setTimeout(function(){e(i.currentTarget).tooltip("hide")},1500)}function y(i){const o=e(i.target).closest("[data-submission-id]").data("submission-id");if(!o){alert("Submission ID is not defined.");return}const s=e(i.target).text(),n=prompt("Enter the new value for the submission:",s);n!==null&&n.trim()!==""?l.fetch(`/api/v1/submissions/${o}`,{method:"PATCH",credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"},body:JSON.stringify({value:n.trim()})}).then(window.location.reload()):alert("Invalid input. Update canceled.")}e(()=>{e("#show-full-flags-button").click(m),e("#show-short-flags-button").click(m),e(".show-flag").click(w),e(".copy-flag").click(v),e("#correct-flags-button").click(b),e(".delete-correct-submission").click(h),e("#submission-delete-button").click(g),e(".submission-value").click(y)});let d=document.getElementsByClassName("imageContainer");for(let i=0;i<d.length;i++)f(d[i]); diff --git a/CTFd/themes/admin/static/assets/pages/team.01ab4652.js b/CTFd/themes/admin/static/assets/pages/team.ef99a2c2.js similarity index 98% rename from CTFd/themes/admin/static/assets/pages/team.01ab4652.js rename to CTFd/themes/admin/static/assets/pages/team.ef99a2c2.js index 74e836829bb448eee8201840e48b8721e46fa6a0..d86bfaa36c5b0bd5d6461c8b6a61542a5a214d16 100644 --- a/CTFd/themes/admin/static/assets/pages/team.01ab4652.js +++ b/CTFd/themes/admin/static/assets/pages/team.ef99a2c2.js @@ -1,4 +1,4 @@ -import{_ as P,C as d,z as _,u as b,c as v,a as p,h as x,l as J,m as E,F as j,r as N,b as D,o as g,j as R,t as $,q as U,$ as e,P as T,Q as z,V as q,B as F}from"./main.9b987665.js";import{c as A,u as S}from"../graphs.10b6af37.js";import{C as B}from"../CommentBox.d08ed1e6.js";import{s as V}from"../visual.9f12da04.js";import"../echarts.common.e43059b8.js";const L={name:"UserAddForm",props:{team_id:Number},data:function(){return{searchedName:"",awaitingSearch:!1,emptyResults:!1,userResults:[],selectedResultIdx:0,selectedUsers:[]}},methods:{searchUsers:function(){if(this.selectedResultIdx=0,this.searchedName==""){this.userResults=[];return}d.fetch(`/api/v1/users?view=admin&field=name&q=${this.searchedName}`,{method:"GET",credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"}}).then(t=>t.json()).then(t=>{t.success&&(this.userResults=t.data.slice(0,10))})},moveCursor:function(t){switch(t){case"up":this.selectedResultIdx&&(this.selectedResultIdx-=1);break;case"down":this.selectedResultIdx<this.userResults.length-1&&(this.selectedResultIdx+=1);break}},selectUser:function(t){t===void 0&&(t=this.selectedResultIdx);let s=this.userResults[t];this.selectedUsers.some(n=>n.id===s.id)===!1&&this.selectedUsers.push(s),this.userResults=[],this.searchedName=""},removeSelectedUser:function(t){this.selectedUsers=this.selectedUsers.filter(s=>s.id!==t)},handleAddUsersRequest:function(){let t=[];return this.selectedUsers.forEach(s=>{let i={user_id:s.id};t.push(d.fetch(`/api/v1/teams/${this.$props.team_id}/members`,{method:"POST",credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"},body:JSON.stringify(i)}))}),Promise.all(t)},handleRemoveUsersFromTeams:function(){let t=[];return this.selectedUsers.forEach(s=>{let i={user_id:s.id};t.push(d.fetch(`/api/v1/teams/${s.team_id}/members`,{method:"DELETE",body:JSON.stringify(i)}))}),Promise.all(t)},addUsers:function(){let t=[];if(this.selectedUsers.forEach(s=>{s.team_id&&t.push(s.name)}),t.length){let s=_(t.join(", "));b({title:"Confirm Team Removal",body:`Les utilisateurs suivants sont actuellement dans une \xE9quipe:<br><br> ${s} <br><br>\xCAtes vous sur de vouloir les retirer de leur \xE9quipe et de les ajouter \xE0 celle-ci? <br><br>Tous leurs d\xE9fis r\xE9solus, tentatives, r\xE9compenses et indices vont \xEAtre supprim\xE9s!`,success:()=>{this.handleRemoveUsersFromTeams().then(i=>{this.handleAddUsersRequest().then(n=>{window.location.reload()})})}})}else this.handleAddUsersRequest().then(s=>{window.location.reload()})}},watch:{searchedName:function(t){this.awaitingSearch===!1&&setTimeout(()=>{this.searchUsers(),this.awaitingSearch=!1},1e3),this.awaitingSearch=!0}}},G={class:"form-group"},H=p("label",null,"Search Users",-1),K={class:"form-group"},Q=["onClick"],Y={class:"form-group"},W={key:0,class:"text-center"},X=p("span",{class:"text-muted"}," No users found ",-1),Z=[X],ee={class:"list-group"},te=["onClick"],se={class:"form-group"};function ie(t,s,i,n,l,r){return g(),v("div",null,[p("div",G,[H,x(p("input",{type:"text",class:"form-control",placeholder:"Search for users","onUpdate:modelValue":s[0]||(s[0]=a=>t.searchedName=a),onKeyup:[s[1]||(s[1]=E(a=>r.moveCursor("down"),["down"])),s[2]||(s[2]=E(a=>r.moveCursor("up"),["up"])),s[3]||(s[3]=E(a=>r.selectUser(),["enter"]))]},null,544),[[J,t.searchedName]])]),p("div",K,[(g(!0),v(j,null,N(t.selectedUsers,a=>(g(),v("span",{class:"badge badge-primary mr-1",key:a.id},[R($(a.name)+" ",1),p("a",{class:"btn-fa",onClick:c=>r.removeSelectedUser(a.id)}," \xD7",8,Q)]))),128))]),p("div",Y,[t.userResults.length==0&&this.searchedName!=""&&t.awaitingSearch==!1?(g(),v("div",W,Z)):D("",!0),p("ul",ee,[(g(!0),v(j,null,N(t.userResults,(a,c)=>(g(),v("li",{class:U({"list-group-item":!0,active:c===t.selectedResultIdx}),key:a.id,onClick:w=>r.selectUser(c)},[R($(a.name)+" ",1),a.team_id?(g(),v("small",{key:0,class:U({"float-right":!0,"text-white":c===t.selectedResultIdx,"text-muted":c!==t.selectedResultIdx})}," already in a team ",2)):D("",!0)],10,te))),128))])]),p("div",se,[p("button",{class:"btn btn-success d-inline-block float-right",onClick:s[4]||(s[4]=a=>r.addUsers())}," Add Users ")])])}const ne=P(L,[["render",ie]]);window.CTFd=d;function ae(t){t.preventDefault();const s=e("#team-info-create-form").serializeJSON(!0);s.fields=[];for(const i in s)if(i.match(/fields\[\d+\]/)){let n={},l=parseInt(i.slice(7,-1));n.field_id=l,n.value=s[i],s.fields.push(n),delete s[i]}d.fetch("/api/v1/teams",{method:"POST",credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"},body:JSON.stringify(s)}).then(function(i){return i.json()}).then(function(i){console.log(i),i.success?(i.data.id,window.location=d.config.urlRoot+"/admin/teams"):(e("#team-info-create-form > #results").empty(),Object.keys(i.errors).forEach(function(n,l){e("#team-info-create-form > #results").append(T({type:"error",body:i.errors[n]}));const r=e("#team-info-create-form").find("input[name={0}]".format(n)),a=e(r);a.addClass("input-filled-invalid"),a.removeClass("input-filled-valid")}))})}function oe(t){t.preventDefault();let s=e("#team-info-edit-form").serializeJSON(!0);s.fields=[];for(const i in s)if(i.match(/fields\[\d+\]/)){let n={},l=parseInt(i.slice(7,-1));n.field_id=l,n.value=s[i],s.fields.push(n),delete s[i]}d.fetch("/api/v1/teams/"+window.TEAM_ID,{method:"PATCH",credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"},body:JSON.stringify(s)}).then(function(i){return i.json()}).then(function(i){i.success?window.location.reload():(e("#team-info-form > #results").empty(),Object.keys(i.errors).forEach(function(n,l){e("#team-info-form > #results").append(T({type:"error",body:i.errors[n]}));const r=e("#team-info-form").find("input[name={0}]".format(n)),a=e(r);a.addClass("input-filled-invalid"),a.removeClass("input-filled-valid")}))})}function M(t){let i=e("input[data-submission-type=incorrect]:checked").map(function(){return e(this).data("submission-id")}),n=i.length===1?"submission":"submissions";b({title:"Valider une soumission",body:`\xCAtes vous sur de vouloir marquer ${i.length} ${n} correct?`,success:function(){const l=[];for(var r of i){let a=d.fetch(`/api/v1/submissions/${r}`,{method:"PATCH",credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"},body:JSON.stringify({type:"correct"})});l.push(a)}Promise.all(l).then(a=>{window.location.reload()})}})}function I(t,s){let i,n,l;switch(s){case"solves":i=e("input[data-submission-type=correct]:checked"),n="solve",l="Solves";break;case"fails":i=e("input[data-submission-type=incorrect]:checked"),n="fail",l="Fails";break}let r=i.map(function(){return e(this).data("submission-id")}),a=r.length===1?n:n+"s";b({title:`Supprimer ${l}`,body:`\xCAtes-vous certain de vouloir supprimer ${r.length} ${a}? (Si le d\xE9fi a d\xE9j\xE0 \xE9t\xE9 approuv\xE9, veuillez \xE9galement le supprimer dans les onglets de soumissions.)`,success:function(){const c=[];for(var w of r)c.push(d.api.delete_submission({submissionId:w}));Promise.all(c).then(C=>{window.location.reload()})}})}function re(t){let s=e("input[data-award-id]:checked").map(function(){return e(this).data("award-id")}),i=s.length===1?"award":"awards";b({title:"Supprimer Awards",body:`\xCAtes-vous certain de vouloir supprimer ${s.length} ${i}?`,success:function(){const n=[];for(var l of s){let r=d.fetch("/api/v1/awards/"+l,{method:"DELETE",credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"}});n.push(r)}Promise.all(n).then(r=>{window.location.reload()})}})}function le(t){t.preventDefault();let s=e("input[data-missing-challenge-id]:checked").map(function(){return e(this).data("missing-challenge-id")}),i=s.length===1?"challenge":"challenges";b({title:"Marquer Correct",body:`\xCAtes-vous s\xFBr de vouloir marquer ${s.length} ${i} correct pour ${_(window.TEAM_NAME)}?`,success:function(){F({title:"Attribution de l'utilisateur",body:` +import{_ as P,C as d,z as _,u as b,c as v,a as p,h as x,l as J,m as E,F as j,r as N,b as D,o as g,j as R,t as $,q as U,$ as e,P as T,Q as z,V as q,B as F}from"./main.71d0edc5.js";import{c as A,u as S}from"../graphs.253aebe5.js";import{C as B}from"../CommentBox.f5ce8d13.js";import{s as V}from"../visual.0867334a.js";import"../echarts.common.a0aaa3a0.js";const L={name:"UserAddForm",props:{team_id:Number},data:function(){return{searchedName:"",awaitingSearch:!1,emptyResults:!1,userResults:[],selectedResultIdx:0,selectedUsers:[]}},methods:{searchUsers:function(){if(this.selectedResultIdx=0,this.searchedName==""){this.userResults=[];return}d.fetch(`/api/v1/users?view=admin&field=name&q=${this.searchedName}`,{method:"GET",credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"}}).then(t=>t.json()).then(t=>{t.success&&(this.userResults=t.data.slice(0,10))})},moveCursor:function(t){switch(t){case"up":this.selectedResultIdx&&(this.selectedResultIdx-=1);break;case"down":this.selectedResultIdx<this.userResults.length-1&&(this.selectedResultIdx+=1);break}},selectUser:function(t){t===void 0&&(t=this.selectedResultIdx);let s=this.userResults[t];this.selectedUsers.some(n=>n.id===s.id)===!1&&this.selectedUsers.push(s),this.userResults=[],this.searchedName=""},removeSelectedUser:function(t){this.selectedUsers=this.selectedUsers.filter(s=>s.id!==t)},handleAddUsersRequest:function(){let t=[];return this.selectedUsers.forEach(s=>{let i={user_id:s.id};t.push(d.fetch(`/api/v1/teams/${this.$props.team_id}/members`,{method:"POST",credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"},body:JSON.stringify(i)}))}),Promise.all(t)},handleRemoveUsersFromTeams:function(){let t=[];return this.selectedUsers.forEach(s=>{let i={user_id:s.id};t.push(d.fetch(`/api/v1/teams/${s.team_id}/members`,{method:"DELETE",body:JSON.stringify(i)}))}),Promise.all(t)},addUsers:function(){let t=[];if(this.selectedUsers.forEach(s=>{s.team_id&&t.push(s.name)}),t.length){let s=_(t.join(", "));b({title:"Confirm Team Removal",body:`Les utilisateurs suivants sont actuellement dans une \xE9quipe:<br><br> ${s} <br><br>\xCAtes vous sur de vouloir les retirer de leur \xE9quipe et de les ajouter \xE0 celle-ci? <br><br>Tous leurs d\xE9fis r\xE9solus, tentatives, r\xE9compenses et indices vont \xEAtre supprim\xE9s!`,success:()=>{this.handleRemoveUsersFromTeams().then(i=>{this.handleAddUsersRequest().then(n=>{window.location.reload()})})}})}else this.handleAddUsersRequest().then(s=>{window.location.reload()})}},watch:{searchedName:function(t){this.awaitingSearch===!1&&setTimeout(()=>{this.searchUsers(),this.awaitingSearch=!1},1e3),this.awaitingSearch=!0}}},G={class:"form-group"},H=p("label",null,"Search Users",-1),K={class:"form-group"},Q=["onClick"],Y={class:"form-group"},W={key:0,class:"text-center"},X=p("span",{class:"text-muted"}," No users found ",-1),Z=[X],ee={class:"list-group"},te=["onClick"],se={class:"form-group"};function ie(t,s,i,n,l,r){return g(),v("div",null,[p("div",G,[H,x(p("input",{type:"text",class:"form-control",placeholder:"Search for users","onUpdate:modelValue":s[0]||(s[0]=a=>t.searchedName=a),onKeyup:[s[1]||(s[1]=E(a=>r.moveCursor("down"),["down"])),s[2]||(s[2]=E(a=>r.moveCursor("up"),["up"])),s[3]||(s[3]=E(a=>r.selectUser(),["enter"]))]},null,544),[[J,t.searchedName]])]),p("div",K,[(g(!0),v(j,null,N(t.selectedUsers,a=>(g(),v("span",{class:"badge badge-primary mr-1",key:a.id},[R($(a.name)+" ",1),p("a",{class:"btn-fa",onClick:c=>r.removeSelectedUser(a.id)}," \xD7",8,Q)]))),128))]),p("div",Y,[t.userResults.length==0&&this.searchedName!=""&&t.awaitingSearch==!1?(g(),v("div",W,Z)):D("",!0),p("ul",ee,[(g(!0),v(j,null,N(t.userResults,(a,c)=>(g(),v("li",{class:U({"list-group-item":!0,active:c===t.selectedResultIdx}),key:a.id,onClick:w=>r.selectUser(c)},[R($(a.name)+" ",1),a.team_id?(g(),v("small",{key:0,class:U({"float-right":!0,"text-white":c===t.selectedResultIdx,"text-muted":c!==t.selectedResultIdx})}," already in a team ",2)):D("",!0)],10,te))),128))])]),p("div",se,[p("button",{class:"btn btn-success d-inline-block float-right",onClick:s[4]||(s[4]=a=>r.addUsers())}," Add Users ")])])}const ne=P(L,[["render",ie]]);window.CTFd=d;function ae(t){t.preventDefault();const s=e("#team-info-create-form").serializeJSON(!0);s.fields=[];for(const i in s)if(i.match(/fields\[\d+\]/)){let n={},l=parseInt(i.slice(7,-1));n.field_id=l,n.value=s[i],s.fields.push(n),delete s[i]}d.fetch("/api/v1/teams",{method:"POST",credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"},body:JSON.stringify(s)}).then(function(i){return i.json()}).then(function(i){console.log(i),i.success?(i.data.id,window.location=d.config.urlRoot+"/admin/teams"):(e("#team-info-create-form > #results").empty(),Object.keys(i.errors).forEach(function(n,l){e("#team-info-create-form > #results").append(T({type:"error",body:i.errors[n]}));const r=e("#team-info-create-form").find("input[name={0}]".format(n)),a=e(r);a.addClass("input-filled-invalid"),a.removeClass("input-filled-valid")}))})}function oe(t){t.preventDefault();let s=e("#team-info-edit-form").serializeJSON(!0);s.fields=[];for(const i in s)if(i.match(/fields\[\d+\]/)){let n={},l=parseInt(i.slice(7,-1));n.field_id=l,n.value=s[i],s.fields.push(n),delete s[i]}d.fetch("/api/v1/teams/"+window.TEAM_ID,{method:"PATCH",credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"},body:JSON.stringify(s)}).then(function(i){return i.json()}).then(function(i){i.success?window.location.reload():(e("#team-info-form > #results").empty(),Object.keys(i.errors).forEach(function(n,l){e("#team-info-form > #results").append(T({type:"error",body:i.errors[n]}));const r=e("#team-info-form").find("input[name={0}]".format(n)),a=e(r);a.addClass("input-filled-invalid"),a.removeClass("input-filled-valid")}))})}function M(t){let i=e("input[data-submission-type=incorrect]:checked").map(function(){return e(this).data("submission-id")}),n=i.length===1?"submission":"submissions";b({title:"Valider une soumission",body:`\xCAtes vous sur de vouloir marquer ${i.length} ${n} correct?`,success:function(){const l=[];for(var r of i){let a=d.fetch(`/api/v1/submissions/${r}`,{method:"PATCH",credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"},body:JSON.stringify({type:"correct"})});l.push(a)}Promise.all(l).then(a=>{window.location.reload()})}})}function I(t,s){let i,n,l;switch(s){case"solves":i=e("input[data-submission-type=correct]:checked"),n="solve",l="Solves";break;case"fails":i=e("input[data-submission-type=incorrect]:checked"),n="fail",l="Fails";break}let r=i.map(function(){return e(this).data("submission-id")}),a=r.length===1?n:n+"s";b({title:`Supprimer ${l}`,body:`\xCAtes-vous certain de vouloir supprimer ${r.length} ${a}? (Si le d\xE9fi a d\xE9j\xE0 \xE9t\xE9 approuv\xE9, veuillez \xE9galement le supprimer dans les onglets de soumissions.)`,success:function(){const c=[];for(var w of r)c.push(d.api.delete_submission({submissionId:w}));Promise.all(c).then(C=>{window.location.reload()})}})}function re(t){let s=e("input[data-award-id]:checked").map(function(){return e(this).data("award-id")}),i=s.length===1?"award":"awards";b({title:"Supprimer Awards",body:`\xCAtes-vous certain de vouloir supprimer ${s.length} ${i}?`,success:function(){const n=[];for(var l of s){let r=d.fetch("/api/v1/awards/"+l,{method:"DELETE",credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"}});n.push(r)}Promise.all(n).then(r=>{window.location.reload()})}})}function le(t){t.preventDefault();let s=e("input[data-missing-challenge-id]:checked").map(function(){return e(this).data("missing-challenge-id")}),i=s.length===1?"challenge":"challenges";b({title:"Marquer Correct",body:`\xCAtes-vous s\xFBr de vouloir marquer ${s.length} ${i} correct pour ${_(window.TEAM_NAME)}?`,success:function(){F({title:"Attribution de l'utilisateur",body:` Quel utilisateur dans l'\xE9quipe ${_(window.TEAM_NAME)} a r\xE9solu ces d\xE9fis? <div class="pb-3" id="query-team-member-solve"> ${e("#team-member-select").html()} diff --git a/CTFd/themes/admin/static/assets/pages/teams.eed3858f.js b/CTFd/themes/admin/static/assets/pages/teams.0e292b4f.js similarity index 95% rename from CTFd/themes/admin/static/assets/pages/teams.eed3858f.js rename to CTFd/themes/admin/static/assets/pages/teams.0e292b4f.js index 884de8abde9f35e9aa5c5e1d73983baff8c628b7..02dcc7f2c1a33c979f10479562893a83f8156278 100644 --- a/CTFd/themes/admin/static/assets/pages/teams.eed3858f.js +++ b/CTFd/themes/admin/static/assets/pages/teams.0e292b4f.js @@ -1,4 +1,4 @@ -import{$ as e,u as r,C as n,B as u}from"./main.9b987665.js";function d(s){let t=e("input[data-team-id]:checked").map(function(){return e(this).data("team-id")}),i=t.length===1?"team":"teams";r({title:"Supprimer les \xE9quipes",body:`\xCAtes-vous certain de vouloir supprimer ${t.length} ${i}?`,success:function(){const a=[];for(var o of t)a.push(n.fetch(`/api/v1/teams/${o}`,{method:"DELETE"}));Promise.all(a).then(l=>{window.location.reload()})}})}function c(s){let t=e("input[data-team-id]:checked").map(function(){return e(this).data("team-id")});u({title:"Modifier les \xE9quipes",body:e(` +import{$ as e,u as r,C as n,B as u}from"./main.71d0edc5.js";function d(s){let t=e("input[data-team-id]:checked").map(function(){return e(this).data("team-id")}),i=t.length===1?"team":"teams";r({title:"Supprimer les \xE9quipes",body:`\xCAtes-vous certain de vouloir supprimer ${t.length} ${i}?`,success:function(){const a=[];for(var o of t)a.push(n.fetch(`/api/v1/teams/${o}`,{method:"DELETE"}));Promise.all(a).then(l=>{window.location.reload()})}})}function c(s){let t=e("input[data-team-id]:checked").map(function(){return e(this).data("team-id")});u({title:"Modifier les \xE9quipes",body:e(` <form id="teams-bulk-edit"> <div class="form-group"> <label>Banni</label> diff --git a/CTFd/themes/admin/static/assets/pages/user.3a21faaa.js b/CTFd/themes/admin/static/assets/pages/user.756e0cbb.js similarity index 96% rename from CTFd/themes/admin/static/assets/pages/user.3a21faaa.js rename to CTFd/themes/admin/static/assets/pages/user.756e0cbb.js index 7c109d60fd5ecd865f481657cc937b39eba7bd1a..99f5ce3b84afa1a7a5f92bc195b87cba26d99bbf 100644 --- a/CTFd/themes/admin/static/assets/pages/user.3a21faaa.js +++ b/CTFd/themes/admin/static/assets/pages/user.756e0cbb.js @@ -1 +1 @@ -import{$ as e,V as y,C as c,P as u,u as d,z as w}from"./main.9b987665.js";import{c as m,u as p}from"../graphs.10b6af37.js";import{C as _}from"../CommentBox.d08ed1e6.js";import{s as S}from"../visual.9f12da04.js";import"../echarts.common.e43059b8.js";function C(n){n.preventDefault();const s=e("#user-info-create-form").serializeJSON(!0);s.fields=[];for(const r in s)if(r.match(/fields\[\d+\]/)){let o={},l=parseInt(r.slice(7,-1));o.field_id=l,o.value=s[r],s.fields.push(o),delete s[r]}let t="/api/v1/users";s.notify===!0&&(t=`${t}?notify=true`),delete s.notify,c.fetch(t,{method:"POST",credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"},body:JSON.stringify(s)}).then(function(r){return r.json()}).then(function(r){if(r.success){const o=r.data.id;window.location=c.config.urlRoot+"/admin/users/"+o}else e("#user-info-create-form > #results").empty(),Object.keys(r.errors).forEach(function(o,l){e("#user-info-create-form > #results").append(u({type:"error",body:r.errors[o]}));const a=e("#user-info-form").find("input[name={0}]".format(o)),f=e(a);f.addClass("input-filled-invalid"),f.removeClass("input-filled-valid")})})}function E(n){n.preventDefault();const s=e("#user-info-edit-form").serializeJSON(!0);s.fields=[];for(const t in s)if(t.match(/fields\[\d+\]/)){let i={},r=parseInt(t.slice(7,-1));i.field_id=r,i.value=s[t],s.fields.push(i),delete s[t]}c.fetch("/api/v1/users/"+window.USER_ID,{method:"PATCH",credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"},body:JSON.stringify(s)}).then(function(t){return t.json()}).then(function(t){t.success?window.location.reload():(e("#user-info-edit-form > #results").empty(),Object.keys(t.errors).forEach(function(i,r){e("#user-info-edit-form > #results").append(u({type:"error",body:t.errors[i]}));const o=e("#user-info-edit-form").find("input[name={0}]".format(i)),l=e(o);l.addClass("input-filled-invalid"),l.removeClass("input-filled-valid")}))})}function k(n){n.preventDefault(),d({title:"Supprimer l'utilisateur",body:"\xCAtes-vous certain de vouloir supprimer {0}".format("<strong>"+w(window.USER_NAME)+"</strong>"),success:function(){c.fetch("/api/v1/users/"+window.USER_ID,{method:"DELETE"}).then(function(s){return s.json()}).then(function(s){s.success&&(window.location=c.config.urlRoot+"/admin/users")})}})}function I(n){n.preventDefault();const s=e("#user-award-form").serializeJSON(!0);s.user_id=window.USER_ID,c.fetch("/api/v1/awards",{method:"POST",credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"},body:JSON.stringify(s)}).then(function(t){return t.json()}).then(function(t){t.success?window.location.reload():(e("#user-award-form > #results").empty(),Object.keys(t.errors).forEach(function(i,r){e("#user-award-form > #results").append(u({type:"error",body:t.errors[i]}));const o=e("#user-award-form").find("input[name={0}]".format(i)),l=e(o);l.addClass("input-filled-invalid"),l.removeClass("input-filled-valid")}))})}function j(n){n.preventDefault();var s=e("#user-mail-form").serializeJSON(!0);c.fetch("/api/v1/users/"+window.USER_ID+"/email",{method:"POST",credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"},body:JSON.stringify(s)}).then(function(t){return t.json()}).then(function(t){t.success?(e("#user-mail-form > #results").append(u({type:"success",body:"Courriel envoy\xE9 avec succ\xE8s!"})),e("#user-mail-form").find("input[type=text], textarea").val("")):(e("#user-mail-form > #results").empty(),Object.keys(t.errors).forEach(function(i,r){e("#user-mail-form > #results").append(u({type:"error",body:t.errors[i]}));var o=e("#user-mail-form").find("input[name={0}], textarea[name={0}]".format(i)),l=e(o);l.addClass("input-filled-invalid"),l.removeClass("input-filled-valid")}))})}function v(n){let t=e("input[data-submission-type=incorrect]:checked").map(function(){return e(this).data("submission-id")}),i=t.length===1?"submission":"submissions";d({title:"Valider une soumission",body:`\xCAtes vous sur de vouloir marquer ${t.length} ${i} correct?`,success:function(){const r=[];for(var o of t){let l=c.fetch(`/api/v1/submissions/${o}`,{method:"PATCH",credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"},body:JSON.stringify({type:"correct"})});r.push(l)}Promise.all(r).then(l=>{window.location.reload()})}})}function h(n,s){let t,i,r;switch(s){case"solves":t=e("input[data-submission-type=correct]:checked"),i="solve",r="Solves";break;case"fails":t=e("input[data-submission-type=incorrect]:checked"),i="fail",r="Fails";break}let o=t.map(function(){return e(this).data("submission-id")}),l=o.length===1?i:i+"s";d({title:`Supprimer ${r}`,body:`\xCAtes-vous certain de vouloir supprimer ${o.length} ${l}?`,success:function(){const a=[];for(var f of o)a.push(c.api.delete_submission({submissionId:f}));Promise.all(a).then($=>{window.location.reload()})}})}function D(n){let s=e("input[data-award-id]:checked").map(function(){return e(this).data("award-id")}),t=s.length===1?"award":"awards";d({title:"Supprimer Awards",body:`\xCAtes-vous certain de vouloir supprimer ${s.length} ${t}?`,success:function(){const i=[];for(var r of s){let o=c.fetch("/api/v1/awards/"+r,{method:"DELETE",credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"}});i.push(o)}Promise.all(i).then(o=>{window.location.reload()})}})}function O(n){n.preventDefault();let s=e("input[data-missing-challenge-id]:checked").map(function(){return e(this).data("missing-challenge-id")}),t=s.length===1?"challenge":"challenges";d({title:"Marquer Correct",body:`\xCAtes-vous s\xFBr de vouloir marquer ${s.length} ${t} correct pour ${w(window.USER_NAME)}?`,success:function(){const i=[];for(var r of s){let o={provided:"MARKED AS SOLVED BY ADMIN",user_id:window.USER_ID,team_id:window.TEAM_ID,challenge_id:r,type:"correct"},l=c.fetch("/api/v1/submissions",{method:"POST",credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"},body:JSON.stringify(o)});i.push(l)}Promise.all(i).then(o=>{window.location.reload()})}})}const b={team:[n=>c.api.get_team_solves({teamId:n}),n=>c.api.get_team_fails({teamId:n}),n=>c.api.get_team_awards({teamId:n})],user:[n=>c.api.get_user_solves({userId:n}),n=>c.api.get_user_fails({userId:n}),n=>c.api.get_user_awards({userId:n})]},A=(n,s,t,i)=>{let[r,o,l]=b[n];Promise.all([r(i),o(i),l(i)]).then(a=>{m("score_graph","#score-graph",a,n,s,t,i),m("category_breakdown","#categories-pie-graph",a,n,s,t,i),m("solve_percentages","#keys-pie-graph",a,n,s,t,i)})},T=(n,s,t,i)=>{let[r,o,l]=b[n];Promise.all([r(i),o(i),l(i)]).then(a=>{p("score_graph","#score-graph",a,n,s,t,i),p("category_breakdown","#categories-pie-graph",a,n,s,t,i),p("solve_percentages","#keys-pie-graph",a,n,s,t,i)})};e(()=>{e(".delete-user").click(k),e(".edit-user").click(function(a){e("#user-info-modal").modal("toggle")}),e(".award-user").click(function(a){e("#user-award-modal").modal("toggle")}),e(".email-user").click(function(a){e("#user-email-modal").modal("toggle")}),e(".addresses-user").click(function(a){e("#user-addresses-modal").modal("toggle")}),e("#user-mail-form").submit(j),e("#solves-delete-button").click(function(a){h(a,"solves")}),e("#correct-fail-button").click(v),e("#correct-submissions-button").click(v),e("#fails-delete-button").click(function(a){h(a,"fails")}),e("#submissions-delete-button").click(function(a){h(a,"fails")}),e("#awards-delete-button").click(function(a){D()}),e("#missing-solve-button").click(function(a){O(a)}),e("#user-info-create-form").submit(C),e("#user-info-edit-form").submit(E),e("#user-award-form").submit(I);const n=y.extend(_);let s=document.createElement("div");document.querySelector("#comment-box").appendChild(s),new n({propsData:{type:"user",id:window.USER_ID}}).$mount(s);let t,i,r,o;({type:t,id:i,name:r,account_id:o}=window.stats_data);let l;e("#user-statistics-modal").on("shown.bs.modal",function(a){A(t,i,r,o),l=setInterval(()=>{T(t,i,r,o)},3e5)}),e("#user-statistics-modal").on("hidden.bs.modal",function(a){clearInterval(l)}),e(".statistics-user").click(function(a){e("#user-statistics-modal").modal("toggle")})});let g=document.getElementsByClassName("imageContainer");for(let n=0;n<g.length;n++)S(g[n]); +import{$ as e,V as y,C as c,P as u,u as d,z as w}from"./main.71d0edc5.js";import{c as m,u as p}from"../graphs.253aebe5.js";import{C as _}from"../CommentBox.f5ce8d13.js";import{s as S}from"../visual.0867334a.js";import"../echarts.common.a0aaa3a0.js";function C(n){n.preventDefault();const s=e("#user-info-create-form").serializeJSON(!0);s.fields=[];for(const r in s)if(r.match(/fields\[\d+\]/)){let o={},l=parseInt(r.slice(7,-1));o.field_id=l,o.value=s[r],s.fields.push(o),delete s[r]}let t="/api/v1/users";s.notify===!0&&(t=`${t}?notify=true`),delete s.notify,c.fetch(t,{method:"POST",credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"},body:JSON.stringify(s)}).then(function(r){return r.json()}).then(function(r){if(r.success){const o=r.data.id;window.location=c.config.urlRoot+"/admin/users/"+o}else e("#user-info-create-form > #results").empty(),Object.keys(r.errors).forEach(function(o,l){e("#user-info-create-form > #results").append(u({type:"error",body:r.errors[o]}));const a=e("#user-info-form").find("input[name={0}]".format(o)),f=e(a);f.addClass("input-filled-invalid"),f.removeClass("input-filled-valid")})})}function E(n){n.preventDefault();const s=e("#user-info-edit-form").serializeJSON(!0);s.fields=[];for(const t in s)if(t.match(/fields\[\d+\]/)){let i={},r=parseInt(t.slice(7,-1));i.field_id=r,i.value=s[t],s.fields.push(i),delete s[t]}c.fetch("/api/v1/users/"+window.USER_ID,{method:"PATCH",credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"},body:JSON.stringify(s)}).then(function(t){return t.json()}).then(function(t){t.success?window.location.reload():(e("#user-info-edit-form > #results").empty(),Object.keys(t.errors).forEach(function(i,r){e("#user-info-edit-form > #results").append(u({type:"error",body:t.errors[i]}));const o=e("#user-info-edit-form").find("input[name={0}]".format(i)),l=e(o);l.addClass("input-filled-invalid"),l.removeClass("input-filled-valid")}))})}function k(n){n.preventDefault(),d({title:"Supprimer l'utilisateur",body:"\xCAtes-vous certain de vouloir supprimer {0}".format("<strong>"+w(window.USER_NAME)+"</strong>"),success:function(){c.fetch("/api/v1/users/"+window.USER_ID,{method:"DELETE"}).then(function(s){return s.json()}).then(function(s){s.success&&(window.location=c.config.urlRoot+"/admin/users")})}})}function I(n){n.preventDefault();const s=e("#user-award-form").serializeJSON(!0);s.user_id=window.USER_ID,c.fetch("/api/v1/awards",{method:"POST",credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"},body:JSON.stringify(s)}).then(function(t){return t.json()}).then(function(t){t.success?window.location.reload():(e("#user-award-form > #results").empty(),Object.keys(t.errors).forEach(function(i,r){e("#user-award-form > #results").append(u({type:"error",body:t.errors[i]}));const o=e("#user-award-form").find("input[name={0}]".format(i)),l=e(o);l.addClass("input-filled-invalid"),l.removeClass("input-filled-valid")}))})}function j(n){n.preventDefault();var s=e("#user-mail-form").serializeJSON(!0);c.fetch("/api/v1/users/"+window.USER_ID+"/email",{method:"POST",credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"},body:JSON.stringify(s)}).then(function(t){return t.json()}).then(function(t){t.success?(e("#user-mail-form > #results").append(u({type:"success",body:"Courriel envoy\xE9 avec succ\xE8s!"})),e("#user-mail-form").find("input[type=text], textarea").val("")):(e("#user-mail-form > #results").empty(),Object.keys(t.errors).forEach(function(i,r){e("#user-mail-form > #results").append(u({type:"error",body:t.errors[i]}));var o=e("#user-mail-form").find("input[name={0}], textarea[name={0}]".format(i)),l=e(o);l.addClass("input-filled-invalid"),l.removeClass("input-filled-valid")}))})}function v(n){let t=e("input[data-submission-type=incorrect]:checked").map(function(){return e(this).data("submission-id")}),i=t.length===1?"submission":"submissions";d({title:"Valider une soumission",body:`\xCAtes vous sur de vouloir marquer ${t.length} ${i} correct?`,success:function(){const r=[];for(var o of t){let l=c.fetch(`/api/v1/submissions/${o}`,{method:"PATCH",credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"},body:JSON.stringify({type:"correct"})});r.push(l)}Promise.all(r).then(l=>{window.location.reload()})}})}function h(n,s){let t,i,r;switch(s){case"solves":t=e("input[data-submission-type=correct]:checked"),i="solve",r="Solves";break;case"fails":t=e("input[data-submission-type=incorrect]:checked"),i="fail",r="Fails";break}let o=t.map(function(){return e(this).data("submission-id")}),l=o.length===1?i:i+"s";d({title:`Supprimer ${r}`,body:`\xCAtes-vous certain de vouloir supprimer ${o.length} ${l}?`,success:function(){const a=[];for(var f of o)a.push(c.api.delete_submission({submissionId:f}));Promise.all(a).then($=>{window.location.reload()})}})}function D(n){let s=e("input[data-award-id]:checked").map(function(){return e(this).data("award-id")}),t=s.length===1?"award":"awards";d({title:"Supprimer Awards",body:`\xCAtes-vous certain de vouloir supprimer ${s.length} ${t}?`,success:function(){const i=[];for(var r of s){let o=c.fetch("/api/v1/awards/"+r,{method:"DELETE",credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"}});i.push(o)}Promise.all(i).then(o=>{window.location.reload()})}})}function O(n){n.preventDefault();let s=e("input[data-missing-challenge-id]:checked").map(function(){return e(this).data("missing-challenge-id")}),t=s.length===1?"challenge":"challenges";d({title:"Marquer Correct",body:`\xCAtes-vous s\xFBr de vouloir marquer ${s.length} ${t} correct pour ${w(window.USER_NAME)}?`,success:function(){const i=[];for(var r of s){let o={provided:"MARKED AS SOLVED BY ADMIN",user_id:window.USER_ID,team_id:window.TEAM_ID,challenge_id:r,type:"correct"},l=c.fetch("/api/v1/submissions",{method:"POST",credentials:"same-origin",headers:{Accept:"application/json","Content-Type":"application/json"},body:JSON.stringify(o)});i.push(l)}Promise.all(i).then(o=>{window.location.reload()})}})}const b={team:[n=>c.api.get_team_solves({teamId:n}),n=>c.api.get_team_fails({teamId:n}),n=>c.api.get_team_awards({teamId:n})],user:[n=>c.api.get_user_solves({userId:n}),n=>c.api.get_user_fails({userId:n}),n=>c.api.get_user_awards({userId:n})]},A=(n,s,t,i)=>{let[r,o,l]=b[n];Promise.all([r(i),o(i),l(i)]).then(a=>{m("score_graph","#score-graph",a,n,s,t,i),m("category_breakdown","#categories-pie-graph",a,n,s,t,i),m("solve_percentages","#keys-pie-graph",a,n,s,t,i)})},T=(n,s,t,i)=>{let[r,o,l]=b[n];Promise.all([r(i),o(i),l(i)]).then(a=>{p("score_graph","#score-graph",a,n,s,t,i),p("category_breakdown","#categories-pie-graph",a,n,s,t,i),p("solve_percentages","#keys-pie-graph",a,n,s,t,i)})};e(()=>{e(".delete-user").click(k),e(".edit-user").click(function(a){e("#user-info-modal").modal("toggle")}),e(".award-user").click(function(a){e("#user-award-modal").modal("toggle")}),e(".email-user").click(function(a){e("#user-email-modal").modal("toggle")}),e(".addresses-user").click(function(a){e("#user-addresses-modal").modal("toggle")}),e("#user-mail-form").submit(j),e("#solves-delete-button").click(function(a){h(a,"solves")}),e("#correct-fail-button").click(v),e("#correct-submissions-button").click(v),e("#fails-delete-button").click(function(a){h(a,"fails")}),e("#submissions-delete-button").click(function(a){h(a,"fails")}),e("#awards-delete-button").click(function(a){D()}),e("#missing-solve-button").click(function(a){O(a)}),e("#user-info-create-form").submit(C),e("#user-info-edit-form").submit(E),e("#user-award-form").submit(I);const n=y.extend(_);let s=document.createElement("div");document.querySelector("#comment-box").appendChild(s),new n({propsData:{type:"user",id:window.USER_ID}}).$mount(s);let t,i,r,o;({type:t,id:i,name:r,account_id:o}=window.stats_data);let l;e("#user-statistics-modal").on("shown.bs.modal",function(a){A(t,i,r,o),l=setInterval(()=>{T(t,i,r,o)},3e5)}),e("#user-statistics-modal").on("hidden.bs.modal",function(a){clearInterval(l)}),e(".statistics-user").click(function(a){e("#user-statistics-modal").modal("toggle")})});let g=document.getElementsByClassName("imageContainer");for(let n=0;n<g.length;n++)S(g[n]); diff --git a/CTFd/themes/admin/static/assets/pages/users.3a9a811e.js b/CTFd/themes/admin/static/assets/pages/users.8086917d.js similarity index 96% rename from CTFd/themes/admin/static/assets/pages/users.3a9a811e.js rename to CTFd/themes/admin/static/assets/pages/users.8086917d.js index 32d75604c1c7a6854c7367ad68f7fa4db2a72ae8..8d4a5f2fcf38364c6427c0f00c94809a3fa9d330 100644 --- a/CTFd/themes/admin/static/assets/pages/users.3a9a811e.js +++ b/CTFd/themes/admin/static/assets/pages/users.8086917d.js @@ -1,4 +1,4 @@ -import{$ as e,u as n,C as a,B as u}from"./main.9b987665.js";function d(l){let t=e("input[data-user-id]:checked").map(function(){return e(this).data("user-id")}),o=t.length===1?"user":"users";n({title:"Supprimer les utilisateurs",body:`\xCAtes-vous certain de vouloir supprimer ${t.length} ${o}?`,success:function(){const i=[];for(var s of t)i.push(a.fetch(`/api/v1/users/${s}`,{method:"DELETE"}));Promise.all(i).then(r=>{window.location.reload()})}})}function c(l){let t=e("input[data-user-id]:checked").map(function(){return e(this).data("user-id")});u({title:"Edit Users",body:e(` +import{$ as e,u as n,C as a,B as u}from"./main.71d0edc5.js";function d(l){let t=e("input[data-user-id]:checked").map(function(){return e(this).data("user-id")}),o=t.length===1?"user":"users";n({title:"Supprimer les utilisateurs",body:`\xCAtes-vous certain de vouloir supprimer ${t.length} ${o}?`,success:function(){const i=[];for(var s of t)i.push(a.fetch(`/api/v1/users/${s}`,{method:"DELETE"}));Promise.all(i).then(r=>{window.location.reload()})}})}function c(l){let t=e("input[data-user-id]:checked").map(function(){return e(this).data("user-id")});u({title:"Edit Users",body:e(` <form id="users-bulk-edit"> <div class="form-group"> <label>V\xE9rifi\xE9</label> diff --git a/CTFd/themes/admin/static/assets/tab.39c73246.js b/CTFd/themes/admin/static/assets/tab.facb6ef1.js similarity index 98% rename from CTFd/themes/admin/static/assets/tab.39c73246.js rename to CTFd/themes/admin/static/assets/tab.facb6ef1.js index 05e312236c6bee5ede6132eae84abf46174d72e5..7957a5dc2c4d93419f7bfd790f152543fbba1811 100644 --- a/CTFd/themes/admin/static/assets/tab.39c73246.js +++ b/CTFd/themes/admin/static/assets/tab.facb6ef1.js @@ -1,4 +1,4 @@ -import{E as V,G as S,H as w}from"./pages/main.9b987665.js";var P={exports:{}};/*! +import{E as V,G as S,H as w}from"./pages/main.71d0edc5.js";var P={exports:{}};/*! * Bootstrap tab.js v4.3.1 (https://getbootstrap.com/) * Copyright 2011-2019 The Bootstrap Authors (https://github.com/twbs/bootstrap/graphs/contributors) * Licensed under MIT (https://github.com/twbs/bootstrap/blob/master/LICENSE) diff --git a/CTFd/themes/admin/static/assets/visual.9f12da04.js b/CTFd/themes/admin/static/assets/visual.0867334a.js similarity index 98% rename from CTFd/themes/admin/static/assets/visual.9f12da04.js rename to CTFd/themes/admin/static/assets/visual.0867334a.js index d87a9e5fb19a50ed29b21ac58bf4b34d97110fd0..22336ab0d0b5ede52c0f646c66b55fd6ee49be9d 100644 --- a/CTFd/themes/admin/static/assets/visual.9f12da04.js +++ b/CTFd/themes/admin/static/assets/visual.0867334a.js @@ -1 +1 @@ -import{B as r}from"./pages/main.9b987665.js";window.carouselPosition=0;window.carouselMax=0;async function u(t){let e=t.id,l;try{l=JSON.parse(e),l%10==l%10&&(l=!1)}catch{}if(console.log(e),l){let s=!1;for(let o=0;o<l.length;o++)if(l[o].type=="thumbsnail"){s=!0;let i=a(l[o]);i.style.width="50px",i.style.height="auto",t.appendChild(i),t.onclick=c}if(!s){let o=document.createElement("p");o.textContent="Pas de miniature disponible pour les m\xE9dias actuels",t.appendChild(o)}}else if(e.length>66){let s=document.createElement("i");s.className="fas fa-file-alt",s.style.cursor="pointer",s.style.fontSize="24px",s.onclick=function(){d(e)},t.appendChild(s)}else{let s=document.createElement("p");s.textContent=e,s.style.wordWrap="break-word",t.appendChild(s)}}function d(t){let e=document.createElement("div");e.style.position="fixed",e.style.left="0",e.style.top="0",e.style.width="100%",e.style.height="100%",e.style.backgroundColor="rgba(0, 0, 0, 0.5)",e.style.zIndex="999",e.onclick=function(i){i.target===e&&document.body.removeChild(e)};let l=document.createElement("div");l.style.position="fixed",l.style.left="50%",l.style.top="50%",l.style.transform="translate(-50%, -50%)",l.style.backgroundColor="#f9f9f9",l.style.border="1px solid #ccc",l.style.borderRadius="8px",l.style.padding="20px",l.style.zIndex="1000",l.style.width="80%",l.style.maxWidth="600px",l.style.height="auto",l.style.maxHeight="40%",l.style.overflowY="auto",l.style.boxShadow="0 4px 8px rgba(0, 0, 0, 0.1)";let s=document.createElement("p");s.textContent=t,s.style.wordWrap="break-word",s.style.margin="0",s.style.color="#333",s.style.fontFamily="Arial, sans-serif",l.appendChild(s);let o=document.createElement("button");o.textContent="x",o.className="close",o.ariaLabel="Close",o.style.position="absolute",o.style.top="0px",o.style.right="5px",o.style.cursor="pointer",o.onclick=function(){document.body.removeChild(e)},l.appendChild(o),e.appendChild(l),document.body.appendChild(e)}function a(t){let e;return t.type=="video/webm"?(e=document.createElement("video"),e.controls=!0,e.type="video/webm"):(t.type=="image/png"||t.type=="thumbsnail")&&(e=document.createElement("img"),e.type="image/png"),e.src="/files/"+t.location,e}function c(t){window.carouselPosition=0;let e;try{e=JSON.parse(t.srcElement.id)}catch{e=JSON.parse(t.srcElement.parentElement.id)}let l=!1;window.carouselMax=e.length-1;let s="<section class='slider-wrapper'><ul class='slides-container list-unstyled' style:'list-style: none !important;' id='slides-container'>";for(let o=0;o<e.length;o++)if(e[o].type!="thumbsnail"){let i=a(e[o]);i.style.width="100%",i.style.objectFit="contain",i.style.height="500px";let n=document.createElement("div");n.append(i),s+='<li class="slide '+(l?o-1:o)+'slide" style="min-height:50%">',s+=n.innerHTML,s+="</li>"}else l=!0;s+="</ul></section>",s+=`<img src onerror='reloadCarousel(this.parentElement);'><button class='btn btn-primary carousel__navigation-button slide-arrow-prev' id='slide-arrow-prev' onclick='downCarousel(this)' style='display:block;position:absolute;top:40%;left:1rem;'><svg viewBox="0 0 100 100"><path d="M 50,0 L 60,10 L 20,50 L 60,90 L 50,100 L 0,50 Z" class="arrow" fill="white" transform="translate(15,0) rotate(0)"></path></svg></button><button style='position:absolute;top:40%;right:1rem;' class='btn btn-primary carousel__navigation-button slide-arrow-next' id='slide-arrow-next' onclick='upCarousel(this)'><svg viewBox="0 0 100 100"><path d="M 50,0 L 60,10 L 20,50 L 60,90 L 50,100 L 0,50 Z" class="arrow" fill="white" transform="translate(85,100) rotate(180)"></path></svg></button>`,r({title:"Visioneurs",body:s,button:"retour",additionalClassMain:"FullSizeCarousel"}),document.getElementsByClassName("modal-dialog")[0].style.listStyle="none"}window.upCarousel=function(t){window.carouselPosition+=1,window.carouselPosition!=window.carouselMax-1?(window.reloadCarousel(t.parentElement),t.parentElement.getElementsByClassName("slide-arrow-prev")[0].hidden=!1):(window.reloadCarousel(t.parentElement),t.parentElement.getElementsByClassName("slide-arrow-next")[0].hidden=!0,t.parentElement.getElementsByClassName("slide-arrow-prev")[0].hidden=!1)};window.downCarousel=function(t){window.carouselPosition-=1,window.carouselPosition!=0?(window.reloadCarousel(t.parentElement),t.parentElement.getElementsByClassName("slide-arrow-next")[0].hidden=!1):(window.reloadCarousel(t.parentElement),t.parentElement.getElementsByClassName("slide-arrow-prev")[0].hiddend=!0,t.parentElement.getElementsByClassName("slide-arrow-next")[0].hidden=!1)};window.reloadCarousel=function(t){window.carouselPosition==0&&(t.getElementsByClassName("slide-arrow-prev")[0].hidden=!0),window.carouselMax==1&&(t.getElementsByClassName("slide-arrow-next")[0].hidden=!0);for(let e=0;e<window.carouselMax;e++)if(e==window.carouselPosition)t.getElementsByClassName(e+"slide")[0].hidden=!1;else{t.getElementsByClassName(e+"slide")[0].hidden=!0;let l=t.getElementsByClassName(e+"slide")[0].firstChild;l.nodeName=="VIDEO"&&l.pause()}};export{u as s}; +import{B as r}from"./pages/main.71d0edc5.js";window.carouselPosition=0;window.carouselMax=0;async function u(t){let e=t.id,l;try{l=JSON.parse(e),l%10==l%10&&(l=!1)}catch{}if(console.log(e),l){let s=!1;for(let o=0;o<l.length;o++)if(l[o].type=="thumbsnail"){s=!0;let i=a(l[o]);i.style.width="50px",i.style.height="auto",t.appendChild(i),t.onclick=c}if(!s){let o=document.createElement("p");o.textContent="Pas de miniature disponible pour les m\xE9dias actuels",t.appendChild(o)}}else if(e.length>66){let s=document.createElement("i");s.className="fas fa-file-alt",s.style.cursor="pointer",s.style.fontSize="24px",s.onclick=function(){d(e)},t.appendChild(s)}else{let s=document.createElement("p");s.textContent=e,s.style.wordWrap="break-word",t.appendChild(s)}}function d(t){let e=document.createElement("div");e.style.position="fixed",e.style.left="0",e.style.top="0",e.style.width="100%",e.style.height="100%",e.style.backgroundColor="rgba(0, 0, 0, 0.5)",e.style.zIndex="999",e.onclick=function(i){i.target===e&&document.body.removeChild(e)};let l=document.createElement("div");l.style.position="fixed",l.style.left="50%",l.style.top="50%",l.style.transform="translate(-50%, -50%)",l.style.backgroundColor="#f9f9f9",l.style.border="1px solid #ccc",l.style.borderRadius="8px",l.style.padding="20px",l.style.zIndex="1000",l.style.width="80%",l.style.maxWidth="600px",l.style.height="auto",l.style.maxHeight="40%",l.style.overflowY="auto",l.style.boxShadow="0 4px 8px rgba(0, 0, 0, 0.1)";let s=document.createElement("p");s.textContent=t,s.style.wordWrap="break-word",s.style.margin="0",s.style.color="#333",s.style.fontFamily="Arial, sans-serif",l.appendChild(s);let o=document.createElement("button");o.textContent="x",o.className="close",o.ariaLabel="Close",o.style.position="absolute",o.style.top="0px",o.style.right="5px",o.style.cursor="pointer",o.onclick=function(){document.body.removeChild(e)},l.appendChild(o),e.appendChild(l),document.body.appendChild(e)}function a(t){let e;return t.type=="video/webm"?(e=document.createElement("video"),e.controls=!0,e.type="video/webm"):(t.type=="image/png"||t.type=="thumbsnail")&&(e=document.createElement("img"),e.type="image/png"),e.src="/files/"+t.location,e}function c(t){window.carouselPosition=0;let e;try{e=JSON.parse(t.srcElement.id)}catch{e=JSON.parse(t.srcElement.parentElement.id)}let l=!1;window.carouselMax=e.length-1;let s="<section class='slider-wrapper'><ul class='slides-container list-unstyled' style:'list-style: none !important;' id='slides-container'>";for(let o=0;o<e.length;o++)if(e[o].type!="thumbsnail"){let i=a(e[o]);i.style.width="100%",i.style.objectFit="contain",i.style.height="500px";let n=document.createElement("div");n.append(i),s+='<li class="slide '+(l?o-1:o)+'slide" style="min-height:50%">',s+=n.innerHTML,s+="</li>"}else l=!0;s+="</ul></section>",s+=`<img src onerror='reloadCarousel(this.parentElement);'><button class='btn btn-primary carousel__navigation-button slide-arrow-prev' id='slide-arrow-prev' onclick='downCarousel(this)' style='display:block;position:absolute;top:40%;left:1rem;'><svg viewBox="0 0 100 100"><path d="M 50,0 L 60,10 L 20,50 L 60,90 L 50,100 L 0,50 Z" class="arrow" fill="white" transform="translate(15,0) rotate(0)"></path></svg></button><button style='position:absolute;top:40%;right:1rem;' class='btn btn-primary carousel__navigation-button slide-arrow-next' id='slide-arrow-next' onclick='upCarousel(this)'><svg viewBox="0 0 100 100"><path d="M 50,0 L 60,10 L 20,50 L 60,90 L 50,100 L 0,50 Z" class="arrow" fill="white" transform="translate(85,100) rotate(180)"></path></svg></button>`,r({title:"Visioneurs",body:s,button:"retour",additionalClassMain:"FullSizeCarousel"}),document.getElementsByClassName("modal-dialog")[0].style.listStyle="none"}window.upCarousel=function(t){window.carouselPosition+=1,window.carouselPosition!=window.carouselMax-1?(window.reloadCarousel(t.parentElement),t.parentElement.getElementsByClassName("slide-arrow-prev")[0].hidden=!1):(window.reloadCarousel(t.parentElement),t.parentElement.getElementsByClassName("slide-arrow-next")[0].hidden=!0,t.parentElement.getElementsByClassName("slide-arrow-prev")[0].hidden=!1)};window.downCarousel=function(t){window.carouselPosition-=1,window.carouselPosition!=0?(window.reloadCarousel(t.parentElement),t.parentElement.getElementsByClassName("slide-arrow-next")[0].hidden=!1):(window.reloadCarousel(t.parentElement),t.parentElement.getElementsByClassName("slide-arrow-prev")[0].hiddend=!0,t.parentElement.getElementsByClassName("slide-arrow-next")[0].hidden=!1)};window.reloadCarousel=function(t){window.carouselPosition==0&&(t.getElementsByClassName("slide-arrow-prev")[0].hidden=!0),window.carouselMax==1&&(t.getElementsByClassName("slide-arrow-next")[0].hidden=!0);for(let e=0;e<window.carouselMax;e++)if(e==window.carouselPosition)t.getElementsByClassName(e+"slide")[0].hidden=!1;else{t.getElementsByClassName(e+"slide")[0].hidden=!0;let l=t.getElementsByClassName(e+"slide")[0].firstChild;l.nodeName=="VIDEO"&&l.pause()}};export{u as s}; diff --git a/CTFd/themes/admin/static/manifest.json b/CTFd/themes/admin/static/manifest.json index 803316d930bc53e6511643b68fafe969392303a9..5709a446f5e1998599650b0292b3eef35abd83af 100644 --- a/CTFd/themes/admin/static/manifest.json +++ b/CTFd/themes/admin/static/manifest.json @@ -1,24 +1,24 @@ { "assets/js/pages/main.js": { - "file": "assets/pages/main.9b987665.js", + "file": "assets/pages/main.71d0edc5.js", "src": "assets/js/pages/main.js", "isEntry": true }, "assets/js/pages/challenge.js": { - "file": "assets/pages/challenge.97ad70d6.js", + "file": "assets/pages/challenge.5425c3a4.js", "src": "assets/js/pages/challenge.js", "isEntry": true, "imports": [ "assets/js/pages/main.js", - "_tab.39c73246.js", - "_CommentBox.d08ed1e6.js" + "_tab.facb6ef1.js", + "_CommentBox.f5ce8d13.js" ], "css": [ "assets/challenge.66ec3ebe.css" ] }, "assets/js/pages/challenges.js": { - "file": "assets/pages/challenges.6f3449ed.js", + "file": "assets/pages/challenges.a6549073.js", "src": "assets/js/pages/challenges.js", "isEntry": true, "imports": [ @@ -26,17 +26,17 @@ ] }, "assets/js/pages/configs.js": { - "file": "assets/pages/configs.106ed7c5.js", + "file": "assets/pages/configs.1b411858.js", "src": "assets/js/pages/configs.js", "isEntry": true, "imports": [ "assets/js/pages/main.js", - "_tab.39c73246.js", - "_htmlmixed.abcfee66.js" + "_tab.facb6ef1.js", + "_htmlmixed.e85df030.js" ] }, "assets/js/pages/notifications.js": { - "file": "assets/pages/notifications.35d02f62.js", + "file": "assets/pages/notifications.9890ee16.js", "src": "assets/js/pages/notifications.js", "isEntry": true, "imports": [ @@ -44,17 +44,17 @@ ] }, "assets/js/pages/editor.js": { - "file": "assets/pages/editor.4da035f7.js", + "file": "assets/pages/editor.5cc4e4af.js", "src": "assets/js/pages/editor.js", "isEntry": true, "imports": [ "assets/js/pages/main.js", - "_htmlmixed.abcfee66.js", - "_CommentBox.d08ed1e6.js" + "_htmlmixed.e85df030.js", + "_CommentBox.f5ce8d13.js" ] }, "assets/js/pages/pages.js": { - "file": "assets/pages/pages.0091c1b7.js", + "file": "assets/pages/pages.b065c23f.js", "src": "assets/js/pages/pages.js", "isEntry": true, "imports": [ @@ -62,7 +62,7 @@ ] }, "assets/js/pages/reset.js": { - "file": "assets/pages/reset.69d0f171.js", + "file": "assets/pages/reset.07e67875.js", "src": "assets/js/pages/reset.js", "isEntry": true, "imports": [ @@ -70,7 +70,7 @@ ] }, "assets/js/pages/scoreboard.js": { - "file": "assets/pages/scoreboard.47117ad7.js", + "file": "assets/pages/scoreboard.1273237b.js", "src": "assets/js/pages/scoreboard.js", "isEntry": true, "imports": [ @@ -78,37 +78,37 @@ ] }, "assets/js/pages/statistics.js": { - "file": "assets/pages/statistics.f0297493.js", + "file": "assets/pages/statistics.7e5d4d77.js", "src": "assets/js/pages/statistics.js", "isEntry": true, "imports": [ "assets/js/pages/main.js", - "_echarts.common.e43059b8.js" + "_echarts.common.a0aaa3a0.js" ] }, "assets/js/pages/submissions.js": { - "file": "assets/pages/submissions.32ae0189.js", + "file": "assets/pages/submissions.2a80c1be.js", "src": "assets/js/pages/submissions.js", "isEntry": true, "imports": [ "assets/js/pages/main.js", - "_visual.9f12da04.js" + "_visual.0867334a.js" ] }, "assets/js/pages/team.js": { - "file": "assets/pages/team.01ab4652.js", + "file": "assets/pages/team.ef99a2c2.js", "src": "assets/js/pages/team.js", "isEntry": true, "imports": [ "assets/js/pages/main.js", - "_graphs.10b6af37.js", - "_CommentBox.d08ed1e6.js", - "_visual.9f12da04.js", - "_echarts.common.e43059b8.js" + "_graphs.253aebe5.js", + "_CommentBox.f5ce8d13.js", + "_visual.0867334a.js", + "_echarts.common.a0aaa3a0.js" ] }, "assets/js/pages/teams.js": { - "file": "assets/pages/teams.eed3858f.js", + "file": "assets/pages/teams.0e292b4f.js", "src": "assets/js/pages/teams.js", "isEntry": true, "imports": [ @@ -116,19 +116,19 @@ ] }, "assets/js/pages/user.js": { - "file": "assets/pages/user.3a21faaa.js", + "file": "assets/pages/user.756e0cbb.js", "src": "assets/js/pages/user.js", "isEntry": true, "imports": [ "assets/js/pages/main.js", - "_graphs.10b6af37.js", - "_CommentBox.d08ed1e6.js", - "_visual.9f12da04.js", - "_echarts.common.e43059b8.js" + "_graphs.253aebe5.js", + "_CommentBox.f5ce8d13.js", + "_visual.0867334a.js", + "_echarts.common.a0aaa3a0.js" ] }, "assets/js/pages/users.js": { - "file": "assets/pages/users.3a9a811e.js", + "file": "assets/pages/users.8086917d.js", "src": "assets/js/pages/users.js", "isEntry": true, "imports": [ @@ -138,14 +138,14 @@ "_echarts.7b83cee2.js": { "file": "assets/echarts.7b83cee2.js" }, - "_tab.39c73246.js": { - "file": "assets/tab.39c73246.js", + "_tab.facb6ef1.js": { + "file": "assets/tab.facb6ef1.js", "imports": [ "assets/js/pages/main.js" ] }, - "_CommentBox.d08ed1e6.js": { - "file": "assets/CommentBox.d08ed1e6.js", + "_CommentBox.f5ce8d13.js": { + "file": "assets/CommentBox.f5ce8d13.js", "imports": [ "assets/js/pages/main.js" ], @@ -153,29 +153,29 @@ "assets/CommentBox.23213b39.css" ] }, - "_htmlmixed.abcfee66.js": { - "file": "assets/htmlmixed.abcfee66.js", + "_htmlmixed.e85df030.js": { + "file": "assets/htmlmixed.e85df030.js", "imports": [ "assets/js/pages/main.js" ] }, - "_echarts.common.e43059b8.js": { - "file": "assets/echarts.common.e43059b8.js", + "_echarts.common.a0aaa3a0.js": { + "file": "assets/echarts.common.a0aaa3a0.js", "imports": [ "assets/js/pages/main.js" ] }, - "_visual.9f12da04.js": { - "file": "assets/visual.9f12da04.js", + "_visual.0867334a.js": { + "file": "assets/visual.0867334a.js", "imports": [ "assets/js/pages/main.js" ] }, - "_graphs.10b6af37.js": { - "file": "assets/graphs.10b6af37.js", + "_graphs.253aebe5.js": { + "file": "assets/graphs.253aebe5.js", "imports": [ "assets/js/pages/main.js", - "_echarts.common.e43059b8.js" + "_echarts.common.a0aaa3a0.js" ] }, "assets/js/pages/challenge.css": { @@ -196,16 +196,16 @@ "src": "assets/css/admin.scss", "isEntry": true }, - "assets/css/codemirror.scss": { - "file": "assets/codemirror.d74a88bc.css", - "src": "assets/css/codemirror.scss", - "isEntry": true - }, "assets/css/fonts.scss": { "file": "assets/fonts.ffb05726.css", "src": "assets/css/fonts.scss", "isEntry": true }, + "assets/css/codemirror.scss": { + "file": "assets/codemirror.d74a88bc.css", + "src": "assets/css/codemirror.scss", + "isEntry": true + }, "assets/css/main.scss": { "file": "assets/main.088f55c6.css", "src": "assets/css/main.scss", diff --git a/CTFd/themes/admin/templates/challenges/challenge.html b/CTFd/themes/admin/templates/challenges/challenge.html index ce1a76133adca636f3506017215ca5315a30fbbb..0b8c8660b0f14d2bdca98b65373c80351b1409c8 100644 --- a/CTFd/themes/admin/templates/challenges/challenge.html +++ b/CTFd/themes/admin/templates/challenges/challenge.html @@ -88,6 +88,8 @@ <a class="nav-item nav-link small" data-toggle="tab" href="#thumbsnail" role="tab">Miniature</a> + <a class="nav-item nav-link small" data-toggle="tab" href="#files" role="tab">Files</a> + </nav> @@ -112,6 +114,15 @@ </div> </div> </div> + + <div class="tab-pane fade" id="files" role="tabpanel"> + <div class="row"> + <div class="col-md-12"> + <h3 class="text-center py-3 d-block">Files</h3> + {% include "admin/modals/challenges/files.html" %} + </div> + </div> + </div> </div> </div> <div id="challenge-update-container" class="col-md-6"> diff --git a/CTFd/themes/core-beta/templates/teams/join_team.html b/CTFd/themes/core-beta/templates/teams/join_team.html index 6d072151b579fe92a53d555521061c18177178d1..f90a1efb0be02679557597e9002c919cd6c5953d 100644 --- a/CTFd/themes/core-beta/templates/teams/join_team.html +++ b/CTFd/themes/core-beta/templates/teams/join_team.html @@ -48,7 +48,6 @@ </thead> <tbody class="table table-striped " > {% for team in teams %} - <tr > <td class="team-id text-center" data='bcolor: {{team.color}}' :style="`display:flex;justify-content: center;`"> @@ -66,12 +65,7 @@ </b> </td> </tr> - {% endfor %} - - - - </tbody> </table> </div> diff --git a/CTFd/themes/core/assets/js/helpers.js b/CTFd/themes/core/assets/js/helpers.js index 81a49870023ccb1d50d353c106b6f86ec4e2627d..007b1119fd9e4c506d45635017d3b1894c89637e 100644 --- a/CTFd/themes/core/assets/js/helpers.js +++ b/CTFd/themes/core/assets/js/helpers.js @@ -25,6 +25,7 @@ const files = { width: 0, title: "Upload Progress" }); + console.log("DSGSFGSFG"); $.ajax({ url: CTFd.config.urlRoot + "/api/v1/files", data: formData,