From 951c044416e0c9a7f659e5cf800bdb4224753ae5 Mon Sep 17 00:00:00 2001 From: Qin Hai <5372604@qq.com> Date: Fri, 6 Dec 2024 15:18:00 +0800 Subject: [PATCH] Fix/multiple same type nodes dragging (#262) * [fix]multiple load lorad node can't dragging * [fix]multiple load_lora node ,can't drag bug * [fix]control_net_name can't drag * [fix]control net node too choose model type error * [feat]fix type name --- bizyair_frontend | 2 +- js/bizyair_frontend.js | 2 +- js/model_apply.js | 96 +++++++++++++++++++++++++++++------------- 3 files changed, 69 insertions(+), 31 deletions(-) diff --git a/bizyair_frontend b/bizyair_frontend index 83459603..d1d677de 160000 --- a/bizyair_frontend +++ b/bizyair_frontend @@ -1 +1 @@ -Subproject commit 83459603843597dbacf7ea41bb8a9c304d00e196 +Subproject commit d1d677de4f3a611bfa056d96555f5f95f77b603d diff --git a/js/bizyair_frontend.js b/js/bizyair_frontend.js index cff7f9b4..da437f4f 100644 --- a/js/bizyair_frontend.js +++ b/js/bizyair_frontend.js @@ -641,7 +641,7 @@ $$ $$`,"title")},...["note","abstract","info","tip","success","question","warning","failure","danger","bug","example","quote","hint","caution","error","attention"].map(i=>({label:`!!! ${i}`,type:"text",apply:by("!!!",` ${i}`," Title",` !!!`,"title")}))]}};return zwe({override:e?[t,...e]:[t]})},FO=e=>{const t=new ts;return r=>(t.get(e.state)?e.dispatch({effects:t.reconfigure(r)}):e.dispatch({effects:Gt.appendConfig.of(t.of(r))}),!0)};class bRe{constructor(t){mc(this,"view"),mc(this,"maxLength",Number.MAX_SAFE_INTEGER),mc(this,"toggleTabSize"),mc(this,"togglePlaceholder"),mc(this,"setExtensions"),mc(this,"toggleDisabled"),mc(this,"toggleReadOnly"),mc(this,"toggleMaxlength"),this.view=t,this.toggleTabSize=FO(this.view),this.togglePlaceholder=FO(this.view),this.setExtensions=FO(this.view),this.toggleDisabled=FO(this.view),this.toggleReadOnly=FO(this.view),this.toggleMaxlength=FO(this.view)}getValue(){return this.view.state.doc.toString()}setValue(t,n=0,r=this.view.state.doc.length){this.view.dispatch({changes:{from:n,to:r,insert:t}})}getSelectedText(){const{from:t,to:n}=this.view.state.selection.main;return this.view.state.sliceDoc(t,n)}replaceSelectedText(t,n={select:!0,deviationStart:0,deviationEnd:0,replaceAll:!1},r){try{if(n.replaceAll){if(this.setValue(t),t.length>this.maxLength)throw new Error("The input text is too long");return}if(this.view.state.doc.length-this.getSelectedText().length+t.length>this.maxLength)throw new Error("The input text is too long");const{from:i}=this.view.state.selection.main;if(this.view.dispatch(this.view.state.replaceSelection(t)),n.select){const a=i+t.length+n.deviationEnd;this.view.dispatch({selection:{anchor:i+n.deviationStart,head:a}})}this.view.focus()}catch(i){if(i.message==="The input text is too long")Ye.emit(r,vu,{name:"overlength",message:i.message,data:t});else throw i}}setTabSize(t){this.toggleTabSize([Zt.tabSize.of(t),xO.of(" ".repeat(t))])}setPlaceholder(t){this.togglePlaceholder(L0e(t))}focus(t){if(this.view.focus(),!t)return;let n=0,r=0,i=0;switch(t){case"start":break;case"end":{n=r=i=this.getValue().length;break}default:n=t.rangeAnchor||t.cursorPos,r=t.rangeHead||t.cursorPos,i=t.cursorPos}this.view.dispatch({scrollIntoView:!0,selection:Me.create([Me.range(n,r),Me.cursor(i)],1)})}setDisabled(t){this.toggleDisabled([et.editable.of(!t)])}setReadOnly(t){this.toggleReadOnly([Zt.readOnly.of(t)])}setMaxLength(t){this.maxLength=t,this.toggleMaxlength([Zt.changeFilter.of(n=>n.newDoc.length<=t)])}}const yRe=(e,t)=>{const n=gt("editorId"),r=a=>{a instanceof Promise?a.then(o=>{Ye.emit(n,yn,"universal",{generate(){return{targetValue:o}}})}).catch(o=>{console.error(o)}):Ye.emit(n,yn,"universal",{generate(){return{targetValue:a}}})};return a=>{var o,s,l;if(!a.clipboardData)return;if(a.clipboardData.files.length>0){const{files:h}=a.clipboardData;Ye.emit(n,C_,Array.from(h).filter(m=>/image\/.*/.test(m.type))),a.preventDefault();return}const c=a.clipboardData.getData("text/plain"),u=((o=t.value)==null?void 0:o.view.state.selection.main.to)||0,d=((s=t.value)==null?void 0:s.view.state.doc.lineAt(u).from)||0,O=((l=t.value)==null?void 0:l.view.state.doc.sliceString(d,u))||"",f=/!\[.*\]\(\s*$/.test(O),p=/!\[.*\]\((.*)\s?.*\)/.test(c);if(f){const h=e.transformImgUrl(c);r(h),a.preventDefault();return}else if(p){const h=c.match(new RegExp(`(?<=!\\[.*\\]\\()([^)\\s]+)(?=\\s?["']?.*["']?\\))`,"g"));h?Promise.all(h.map(m=>e.transformImgUrl(m))).then(m=>{r(m.reduce((g,_,b)=>g.replace(h[b],_),c))}):r(c),a.preventDefault();return}if(e.autoDetectCode&&a.clipboardData.types.includes("vscode-editor-data")){const h=JSON.parse(a.clipboardData.getData("vscode-editor-data"));Ye.emit(n,yn,"code",{mode:h.mode,text:a.clipboardData.getData("text/plain")}),a.preventDefault();return}e.maxlength&&c.length+e.modelValue.length>e.maxlength&&Ye.emit(n,vu,{name:"overlength",message:"The input text is too long",data:c})}},vRe=(e,t)=>[{key:"Ctrl-b",mac:"Cmd-b",run:()=>(Ye.emit(e,yn,"bold"),!0)},{key:"Ctrl-d",mac:"Cmd-d",run:Q4,preventDefault:!0},{key:"Ctrl-s",mac:"Cmd-s",run:y=>(Ye.emit(e,Q_,y.state.doc.toString()),!0),shift:()=>(Ye.emit(e,yn,"strikeThrough"),!0)},{key:"Ctrl-u",mac:"Cmd-u",preventDefault:!0,run:()=>(Ye.emit(e,yn,"underline"),!0),shift:()=>(Ye.emit(e,yn,"unorderedList"),!0)},{key:"Ctrl-i",mac:"Cmd-i",preventDefault:!0,run:()=>(Ye.emit(e,yn,"italic"),!0),shift:()=>(Ye.emit(e,i$,"image"),!0)},{key:"Ctrl-1",mac:"Cmd-1",run:()=>(Ye.emit(e,yn,"h1"),!0)},{key:"Ctrl-2",mac:"Cmd-2",run:()=>(Ye.emit(e,yn,"h2"),!0)},{key:"Ctrl-3",mac:"Cmd-3",run:()=>(Ye.emit(e,yn,"h3"),!0)},{key:"Ctrl-4",mac:"Cmd-4",run:()=>(Ye.emit(e,yn,"h4"),!0)},{key:"Ctrl-5",mac:"Cmd-5",run:()=>(Ye.emit(e,yn,"h5"),!0)},{key:"Ctrl-6",mac:"Cmd-6",run:()=>(Ye.emit(e,yn,"h6"),!0)},{key:"Ctrl-ArrowUp",mac:"Cmd-ArrowUp",run:()=>(Ye.emit(e,yn,"sup"),!0)},{key:"Ctrl-ArrowDown",mac:"Cmd-ArrowDown",run:()=>(Ye.emit(e,yn,"sub"),!0)},{key:"Ctrl-o",mac:"Cmd-o",run:()=>(Ye.emit(e,yn,"orderedList"),!0)},{key:"Ctrl-c",mac:"Cmd-c",shift:()=>(Ye.emit(e,yn,"code"),!0),any(y,v){return(v.ctrlKey||v.metaKey)&&v.altKey&&v.code==="KeyC"?(Ye.emit(e,yn,"codeRow"),!0):!1}},{key:"Ctrl-l",mac:"Cmd-l",run:()=>(Ye.emit(e,i$,"link"),!0)},{key:"Ctrl-f",mac:"Cmd-f",shift:()=>t.noPrettier?!1:(Ye.emit(e,yn,"prettier"),!0)},{any:(y,v)=>(v.ctrlKey||v.metaKey)&&v.altKey&&v.shiftKey&&v.code==="KeyT"?(Ye.emit(e,yn,"table"),!0):!1},...iwe];et.EDIT_CONTEXT=!1;const SRe=e=>{const t=gt("tabWidth"),n=gt("editorId"),r=gt("theme"),i=xe(),a=Rs(),o=xe(!1),s=new ts,l=new ts,c=new ts,u=new ts,d=new ts,O=vRe(n,e),f=()=>[...O,...X1e,...ZTe,z1e],h={paste:yRe(e,a),blur:e.onBlur,focus:e.onFocus,drop:e.onDrop,compositionstart:()=>{o.value=!0},compositionend:(_,b)=>{o.value=!1,e.updateModelValue(b.state.doc.toString())},input:_=>{e.onInput&&e.onInput(_);const{data:b}=_;e.maxlength&&e.modelValue.length+b.length>e.maxlength&&Ye.emit(n,vu,{name:"overlength",message:"The input text is too long",data:b})}},m=[ah.of(f()),u.of(H6()),s.of(OY({codeLanguages:Wwe})),et.lineWrapping,et.updateListener.of(_=>{_.docChanged&&(e.onChange(_.state.doc.toString()),o.value||e.updateModelValue(_.state.doc.toString()))}),d.of(et.domEventHandlers(h)),A0e()],g=()=>{const _=[...m,l.of(r.value==="light"?TY:_Y),c.of(xY(e.completions))];return Jn.codeMirrorExtensions(r.value,_,f(),{editorId:n})};return ht(()=>{const _=new et({doc:e.modelValue,parent:i.value,extensions:[g()]}),b=new bRe(_);a.value=b,setTimeout(()=>{b.setTabSize(t),b.setDisabled(e.disabled),b.setReadOnly(e.readonly),e.placeholder&&b.setPlaceholder(e.placeholder),typeof e.maxlength=="number"&&b.setMaxLength(e.maxlength),e.autofocus&&_.focus()},0),Ye.on(n,{name:k5,callback(){GP(_)}}),Ye.on(n,{name:C5,callback(){Xb(_)}}),Ye.on(n,{name:yn,async callback(y,v={}){var E,w;if(y==="image"&&v.transform){const T=e.transformImgUrl(v.url);if(T instanceof Promise)T.then(async S=>{var x;const{text:$,options:Q}=await nQ(y,a.value,{...v,url:S});(x=a.value)==null||x.replaceSelectedText($,Q,n)}).catch(S=>{console.error(S)});else{const{text:S,options:x}=await nQ(y,a.value,{...v,url:T});(E=a.value)==null||E.replaceSelectedText(S,x,n)}}else{const{text:T,options:S}=await nQ(y,a.value,v);(w=a.value)==null||w.replaceSelectedText(T,S,n)}}}),Ye.on(n,{name:I5,callback:Yge(y=>{var v;const E={...h},w=Object.keys(h);for(const T in y){const S=T;w.includes(S)?E[S]=(x,$)=>{y[S](x,$),x.defaultPrevented||h[S](x,$)}:E[S]=y[S]}(v=a.value)==null||v.view.dispatch({effects:d.reconfigure(et.domEventHandlers(E))})})}),Ye.on(n,{name:D5,callback:(y,v)=>{const E=_.state.doc.line(y);_.dispatch(_.state.update({changes:{from:E.from,to:E.to,insert:v}}))}})}),Be(r,()=>{var _;(_=a.value)==null||_.view.dispatch({effects:l.reconfigure(r.value==="light"?TY:_Y)})},{deep:!0}),Be(()=>e.completions,()=>{var _;(_=a.value)==null||_.view.dispatch({effects:c.reconfigure(xY(e.completions))})},{deep:!0}),Be(()=>e.modelValue,()=>{var _,b;((_=a.value)==null?void 0:_.getValue())!==e.modelValue&&((b=a.value)==null||b.setValue(e.modelValue))}),Be(()=>e.placeholder,()=>{var _;(_=a.value)==null||_.setPlaceholder(e.placeholder)}),Be(()=>e.disabled,()=>{var _;(_=a.value)==null||_.setDisabled(e.disabled)}),Be(()=>e.readonly,()=>{var _;(_=a.value)==null||_.setDisabled(e.readonly)}),Be(()=>e.maxlength,()=>{var _;e.maxlength&&((_=a.value)==null||_.setMaxLength(e.maxlength))}),{inputWrapperRef:i,codeMirrorUt:a,resetHistory(){var _,b;(_=a.value)==null||_.view.dispatch({effects:u.reconfigure([])}),(b=a.value)==null||b.view.dispatch({effects:u.reconfigure(H6())})}}},ERe=(e,t,n)=>{const r=Hn({resizedWidth:e.inputBoxWidth}),i=Hn({width:e.inputBoxWidth}),a=Hn({left:e.inputBoxWidth,display:"initial"}),o=xe(e.setting.preview||e.setting.htmlPreview),s=u=>{var d,O,f;const p=((d=t.value)==null?void 0:d.offsetWidth)||0,h=((O=t.value)==null?void 0:O.getBoundingClientRect().x)||0;let m=u.x-h;mp-P_&&(m=p-P_);const g=`${m}px`;i.width=g,a.left=g,r.resizedWidth=g,(f=e.oninputBoxWidthChange)==null||f.call(e,g)},l=()=>{document.addEventListener("mousemove",s)},c=()=>{document.removeEventListener("mousemove",s)};return Be([n],()=>{var u,d;(u=n.value)==null||u.addEventListener("mousedown",l),(d=n.value)==null||d.addEventListener("mouseup",c)},{immediate:!0}),Lo(()=>{var u,d;(u=n.value)==null||u.removeEventListener("mousedown",l),(d=n.value)==null||d.removeEventListener("mouseup",c)}),Be(()=>e.inputBoxWidth,u=>{u&&(r.resizedWidth=u,i.width=u,a.left=u)}),Be([ui(e.setting,"htmlPreview"),ui(e.setting,"preview"),ui(e.setting,"previewOnly")],()=>{e.setting.previewOnly?(i.width="0%",a.display="none",o.value=!0):!e.setting.htmlPreview&&!e.setting.preview?(i.width="100%",a.display="none",o.value=!1):(i.width=r.resizedWidth,a.display="initial",o.value=!0)},{immediate:!0}),{inputWrapperStyle:i,resizeOperateStyle:a,showPreviewWrapper:o}},TRe=ve({name:"MDEditorContent",props:Mve,setup(e,t){const n=gt("editorId"),r=xe(""),i=xe(),a=xe(),{inputWrapperRef:o,codeMirrorUt:s,resetHistory:l}=SRe(e),{inputWrapperStyle:c,resizeOperateStyle:u,showPreviewWrapper:d}=ERe(e,i,a);return ZPe(e,r,s),t.expose({getSelectedText(){var O;return(O=s.value)==null?void 0:O.getSelectedText()},focus(O){var f;(f=s.value)==null||f.focus(O)},resetHistory:l,getEditorView(){var O;return(O=s.value)==null?void 0:O.view}}),()=>te("div",{class:`${be}-content${d.value?" has-preview":""}`,ref:i},[te("div",{class:`${be}-input-wrapper`,style:c,ref:o},null),(e.setting.htmlPreview||e.setting.preview)&&te("div",{class:`${be}-resize-operate`,style:u,ref:a},null),d.value&&te(zz,{modelValue:e.modelValue,onChange:e.onChange,setting:e.setting,onHtmlChanged:O=>{r.value=O,e.onHtmlChanged(O)},onGetCatalog:e.onGetCatalog,mdHeadingId:e.mdHeadingId,noMermaid:e.noMermaid,sanitize:e.sanitize,noKatex:e.noKatex,formatCopiedText:e.formatCopiedText,noHighlight:e.noHighlight,noImgZoomIn:e.noImgZoomIn,sanitizeMermaid:e.sanitizeMermaid,codeFoldable:e.codeFoldable,autoFoldThreshold:e.autoFoldThreshold},null),e.catalogVisible&&te(Up,{theme:e.theme,class:`${be}-catalog-editor`,editorId:n,mdHeadingId:e.mdHeadingId,key:"internal-catalog",scrollElementOffsetTop:2},null)])}}),wRe=ve({props:{modelValue:{type:String,default:""}},setup(e){const t=gt("usedLanguageText");return()=>{var n,r;return te("div",{class:`${be}-footer-item`},[te("label",{class:`${be}-footer-label`},[`${(n=t.value.footer)==null?void 0:n.markdownTotal}:`]),te("span",null,[((r=e.modelValue)==null?void 0:r.length)||0])])}}}),xRe={checked:{type:Boolean,default:!1},onChange:{type:Function,default:()=>{}}},$Re=ve({name:`${be}-checkbox`,props:xRe,setup(e){return()=>te("div",{class:[`${be}-checkbox`,e.checked&&`${be}-checkbox-checked`],onClick:()=>{e.onChange(!e.checked)}},null)}}),PRe=ve({props:{scrollAuto:{type:Boolean},onScrollAutoChange:{type:Function,default:()=>{}}},setup(e){const t=gt("usedLanguageText");return()=>{var n;return te("div",{class:`${be}-footer-item`},[te("label",{class:`${be}-footer-label`,onClick:()=>{e.onScrollAutoChange(!e.scrollAuto)}},[(n=t.value.footer)==null?void 0:n.scrollAuto]),te($Re,{checked:e.scrollAuto,onChange:e.onScrollAutoChange},null)])}}}),RRe=ve({name:"MDEditorFooter",props:{modelValue:{type:String,default:""},footers:{type:Array,default:[]},scrollAuto:{type:Boolean},noScrollAuto:{type:Boolean},onScrollAutoChange:{type:Function,default:()=>{}},defFooters:{type:Object}},setup(e){const t=Ie(()=>{const r=e.footers.indexOf("="),i=r===-1?e.footers:e.footers.slice(0,r),a=r===-1?[]:e.footers.slice(r,Number.MAX_SAFE_INTEGER);return[i,a]}),n=r=>{if(S5.includes(r))switch(r){case"markdownTotal":return te(wRe,{modelValue:e.modelValue},null);case"scrollSwitch":return!e.noScrollAuto&&te(PRe,{scrollAuto:e.scrollAuto,onScrollAutoChange:e.onScrollAutoChange},null)}else return e.defFooters instanceof Array?e.defFooters[r]||"":e.defFooters&&e.defFooters.children instanceof Array&&e.defFooters.children[r]||""};return()=>{const r=t.value[0].map(a=>n(a)),i=t.value[1].map(a=>n(a));return te("div",{class:`${be}-footer`},[te("div",{class:`${be}-footer-left`},[r]),te("div",{class:`${be}-footer-right`},[i])])}}}),Mh=ve({name:"MdEditorV3",props:Yve,emits:jve,setup(e,t){const{noKatex:n,noMermaid:r,noPrettier:i,noUploadImg:a,noHighlight:o}=e,s=Hn({scrollAuto:e.scrollAuto}),l=xe(),c=xe(),{editorId:u}=Uve(e,l),[d,O]=Bve(e,t,{editorId:u}),f=Fve(e,{editorId:u});return Lve(e,t,{editorId:u}),Xve(e),zve(e,t,{editorId:u}),Wve(e,t,{editorId:u,catalogVisible:f,setting:d,updateSetting:O,codeRef:c}),Lo(()=>{Ye.clear(u)}),()=>{const p=ji({props:e,ctx:t},"defToolbars"),h=ji({props:e,ctx:t},"defFooters");return te("div",{id:u,class:[be,e.class,e.theme==="dark"&&`${be}-dark`,d.fullscreen||d.pageFullscreen?`${be}-fullscreen`:""],style:e.style,ref:l},[e.toolbars.length>0&&te(GPe,{noPrettier:i,toolbars:e.toolbars,toolbarsExclude:e.toolbarsExclude,setting:d,updateSetting:O,tableShape:e.tableShape,defToolbars:p,noUploadImg:a,showToolbarName:e.showToolbarName,catalogVisible:f.value,codeTheme:e.codeTheme},null),te(TRe,{ref:c,modelValue:e.modelValue,setting:d,mdHeadingId:e.mdHeadingId,noMermaid:r,noPrettier:i,sanitize:e.sanitize,placeholder:e.placeholder,noKatex:n,scrollAuto:s.scrollAuto,formatCopiedText:e.formatCopiedText,autofocus:e.autoFocus,disabled:e.disabled,readonly:e.readOnly,maxlength:e.maxLength,autoDetectCode:e.autoDetectCode,noHighlight:o,updateModelValue:m=>{t.emit("update:modelValue",m)},onChange:m=>{e.onChange&&e.onChange(m),t.emit("onChange",m)},onHtmlChanged:m=>{e.onHtmlChanged&&e.onHtmlChanged(m),t.emit("onHtmlChanged",m)},onGetCatalog:m=>{e.onGetCatalog&&e.onGetCatalog(m),t.emit("onGetCatalog",m)},onBlur:m=>{e.onBlur&&e.onBlur(m),t.emit("onBlur",m)},onFocus:m=>{e.onFocus&&e.onFocus(m),t.emit("onFocus",m)},onInput:m=>{e.onInput&&e.onInput(m),t.emit("onInput",m)},completions:e.completions,catalogVisible:f.value,theme:e.theme,noImgZoomIn:e.noImgZoomIn,onDrop:m=>{e.onDrop&&e.onDrop(m),t.emit("onDrop",m)},inputBoxWidth:e.inputBoxWidth,oninputBoxWidthChange:m=>{e.oninputBoxWidthChange&&e.oninputBoxWidthChange(m),t.emit("oninputBoxWidthChange",m)},sanitizeMermaid:e.sanitizeMermaid,transformImgUrl:e.transformImgUrl,codeFoldable:e.codeFoldable,autoFoldThreshold:e.autoFoldThreshold},null),e.footers.length>0&&te(RRe,{modelValue:e.modelValue,footers:e.footers,defFooters:h,noScrollAuto:!d.preview&&!d.htmlPreview||d.previewOnly,scrollAuto:s.scrollAuto,onScrollAutoChange:m=>s.scrollAuto=m},null)])}}});Mh.install=e=>(e.component(Mh.name,Mh),e.use(hc).use(R_).use(_y).use(Up).use(Lp),e);const aQ=ve({name:"NormalFooterToolbar",props:{onClick:{type:Function,default:void 0}},emits:["onClick"],setup(e,t){return()=>{const n=ji({props:e,ctx:t});return te("div",{class:`${be}-footer-item`,onClick:r=>{e.onClick instanceof Function?e.onClick(r):t.emit("onClick",r)}},[n])}}});aQ.install=e=>(e.component(aQ.name,aQ),e);var $Y={exports:{}},Mn={},oQ={exports:{}},Nu={};function PY(){var e={};return e["align-content"]=!1,e["align-items"]=!1,e["align-self"]=!1,e["alignment-adjust"]=!1,e["alignment-baseline"]=!1,e.all=!1,e["anchor-point"]=!1,e.animation=!1,e["animation-delay"]=!1,e["animation-direction"]=!1,e["animation-duration"]=!1,e["animation-fill-mode"]=!1,e["animation-iteration-count"]=!1,e["animation-name"]=!1,e["animation-play-state"]=!1,e["animation-timing-function"]=!1,e.azimuth=!1,e["backface-visibility"]=!1,e.background=!0,e["background-attachment"]=!0,e["background-clip"]=!0,e["background-color"]=!0,e["background-image"]=!0,e["background-origin"]=!0,e["background-position"]=!0,e["background-repeat"]=!0,e["background-size"]=!0,e["baseline-shift"]=!1,e.binding=!1,e.bleed=!1,e["bookmark-label"]=!1,e["bookmark-level"]=!1,e["bookmark-state"]=!1,e.border=!0,e["border-bottom"]=!0,e["border-bottom-color"]=!0,e["border-bottom-left-radius"]=!0,e["border-bottom-right-radius"]=!0,e["border-bottom-style"]=!0,e["border-bottom-width"]=!0,e["border-collapse"]=!0,e["border-color"]=!0,e["border-image"]=!0,e["border-image-outset"]=!0,e["border-image-repeat"]=!0,e["border-image-slice"]=!0,e["border-image-source"]=!0,e["border-image-width"]=!0,e["border-left"]=!0,e["border-left-color"]=!0,e["border-left-style"]=!0,e["border-left-width"]=!0,e["border-radius"]=!0,e["border-right"]=!0,e["border-right-color"]=!0,e["border-right-style"]=!0,e["border-right-width"]=!0,e["border-spacing"]=!0,e["border-style"]=!0,e["border-top"]=!0,e["border-top-color"]=!0,e["border-top-left-radius"]=!0,e["border-top-right-radius"]=!0,e["border-top-style"]=!0,e["border-top-width"]=!0,e["border-width"]=!0,e.bottom=!1,e["box-decoration-break"]=!0,e["box-shadow"]=!0,e["box-sizing"]=!0,e["box-snap"]=!0,e["box-suppress"]=!0,e["break-after"]=!0,e["break-before"]=!0,e["break-inside"]=!0,e["caption-side"]=!1,e.chains=!1,e.clear=!0,e.clip=!1,e["clip-path"]=!1,e["clip-rule"]=!1,e.color=!0,e["color-interpolation-filters"]=!0,e["column-count"]=!1,e["column-fill"]=!1,e["column-gap"]=!1,e["column-rule"]=!1,e["column-rule-color"]=!1,e["column-rule-style"]=!1,e["column-rule-width"]=!1,e["column-span"]=!1,e["column-width"]=!1,e.columns=!1,e.contain=!1,e.content=!1,e["counter-increment"]=!1,e["counter-reset"]=!1,e["counter-set"]=!1,e.crop=!1,e.cue=!1,e["cue-after"]=!1,e["cue-before"]=!1,e.cursor=!1,e.direction=!1,e.display=!0,e["display-inside"]=!0,e["display-list"]=!0,e["display-outside"]=!0,e["dominant-baseline"]=!1,e.elevation=!1,e["empty-cells"]=!1,e.filter=!1,e.flex=!1,e["flex-basis"]=!1,e["flex-direction"]=!1,e["flex-flow"]=!1,e["flex-grow"]=!1,e["flex-shrink"]=!1,e["flex-wrap"]=!1,e.float=!1,e["float-offset"]=!1,e["flood-color"]=!1,e["flood-opacity"]=!1,e["flow-from"]=!1,e["flow-into"]=!1,e.font=!0,e["font-family"]=!0,e["font-feature-settings"]=!0,e["font-kerning"]=!0,e["font-language-override"]=!0,e["font-size"]=!0,e["font-size-adjust"]=!0,e["font-stretch"]=!0,e["font-style"]=!0,e["font-synthesis"]=!0,e["font-variant"]=!0,e["font-variant-alternates"]=!0,e["font-variant-caps"]=!0,e["font-variant-east-asian"]=!0,e["font-variant-ligatures"]=!0,e["font-variant-numeric"]=!0,e["font-variant-position"]=!0,e["font-weight"]=!0,e.grid=!1,e["grid-area"]=!1,e["grid-auto-columns"]=!1,e["grid-auto-flow"]=!1,e["grid-auto-rows"]=!1,e["grid-column"]=!1,e["grid-column-end"]=!1,e["grid-column-start"]=!1,e["grid-row"]=!1,e["grid-row-end"]=!1,e["grid-row-start"]=!1,e["grid-template"]=!1,e["grid-template-areas"]=!1,e["grid-template-columns"]=!1,e["grid-template-rows"]=!1,e["hanging-punctuation"]=!1,e.height=!0,e.hyphens=!1,e.icon=!1,e["image-orientation"]=!1,e["image-resolution"]=!1,e["ime-mode"]=!1,e["initial-letters"]=!1,e["inline-box-align"]=!1,e["justify-content"]=!1,e["justify-items"]=!1,e["justify-self"]=!1,e.left=!1,e["letter-spacing"]=!0,e["lighting-color"]=!0,e["line-box-contain"]=!1,e["line-break"]=!1,e["line-grid"]=!1,e["line-height"]=!1,e["line-snap"]=!1,e["line-stacking"]=!1,e["line-stacking-ruby"]=!1,e["line-stacking-shift"]=!1,e["line-stacking-strategy"]=!1,e["list-style"]=!0,e["list-style-image"]=!0,e["list-style-position"]=!0,e["list-style-type"]=!0,e.margin=!0,e["margin-bottom"]=!0,e["margin-left"]=!0,e["margin-right"]=!0,e["margin-top"]=!0,e["marker-offset"]=!1,e["marker-side"]=!1,e.marks=!1,e.mask=!1,e["mask-box"]=!1,e["mask-box-outset"]=!1,e["mask-box-repeat"]=!1,e["mask-box-slice"]=!1,e["mask-box-source"]=!1,e["mask-box-width"]=!1,e["mask-clip"]=!1,e["mask-image"]=!1,e["mask-origin"]=!1,e["mask-position"]=!1,e["mask-repeat"]=!1,e["mask-size"]=!1,e["mask-source-type"]=!1,e["mask-type"]=!1,e["max-height"]=!0,e["max-lines"]=!1,e["max-width"]=!0,e["min-height"]=!0,e["min-width"]=!0,e["move-to"]=!1,e["nav-down"]=!1,e["nav-index"]=!1,e["nav-left"]=!1,e["nav-right"]=!1,e["nav-up"]=!1,e["object-fit"]=!1,e["object-position"]=!1,e.opacity=!1,e.order=!1,e.orphans=!1,e.outline=!1,e["outline-color"]=!1,e["outline-offset"]=!1,e["outline-style"]=!1,e["outline-width"]=!1,e.overflow=!1,e["overflow-wrap"]=!1,e["overflow-x"]=!1,e["overflow-y"]=!1,e.padding=!0,e["padding-bottom"]=!0,e["padding-left"]=!0,e["padding-right"]=!0,e["padding-top"]=!0,e.page=!1,e["page-break-after"]=!1,e["page-break-before"]=!1,e["page-break-inside"]=!1,e["page-policy"]=!1,e.pause=!1,e["pause-after"]=!1,e["pause-before"]=!1,e.perspective=!1,e["perspective-origin"]=!1,e.pitch=!1,e["pitch-range"]=!1,e["play-during"]=!1,e.position=!1,e["presentation-level"]=!1,e.quotes=!1,e["region-fragment"]=!1,e.resize=!1,e.rest=!1,e["rest-after"]=!1,e["rest-before"]=!1,e.richness=!1,e.right=!1,e.rotation=!1,e["rotation-point"]=!1,e["ruby-align"]=!1,e["ruby-merge"]=!1,e["ruby-position"]=!1,e["shape-image-threshold"]=!1,e["shape-outside"]=!1,e["shape-margin"]=!1,e.size=!1,e.speak=!1,e["speak-as"]=!1,e["speak-header"]=!1,e["speak-numeral"]=!1,e["speak-punctuation"]=!1,e["speech-rate"]=!1,e.stress=!1,e["string-set"]=!1,e["tab-size"]=!1,e["table-layout"]=!1,e["text-align"]=!0,e["text-align-last"]=!0,e["text-combine-upright"]=!0,e["text-decoration"]=!0,e["text-decoration-color"]=!0,e["text-decoration-line"]=!0,e["text-decoration-skip"]=!0,e["text-decoration-style"]=!0,e["text-emphasis"]=!0,e["text-emphasis-color"]=!0,e["text-emphasis-position"]=!0,e["text-emphasis-style"]=!0,e["text-height"]=!0,e["text-indent"]=!0,e["text-justify"]=!0,e["text-orientation"]=!0,e["text-overflow"]=!0,e["text-shadow"]=!0,e["text-space-collapse"]=!0,e["text-transform"]=!0,e["text-underline-position"]=!0,e["text-wrap"]=!0,e.top=!1,e.transform=!1,e["transform-origin"]=!1,e["transform-style"]=!1,e.transition=!1,e["transition-delay"]=!1,e["transition-duration"]=!1,e["transition-property"]=!1,e["transition-timing-function"]=!1,e["unicode-bidi"]=!1,e["vertical-align"]=!1,e.visibility=!1,e["voice-balance"]=!1,e["voice-duration"]=!1,e["voice-family"]=!1,e["voice-pitch"]=!1,e["voice-range"]=!1,e["voice-rate"]=!1,e["voice-stress"]=!1,e["voice-volume"]=!1,e.volume=!1,e["white-space"]=!1,e.widows=!1,e.width=!0,e["will-change"]=!1,e["word-break"]=!0,e["word-spacing"]=!0,e["word-wrap"]=!0,e["wrap-flow"]=!1,e["wrap-through"]=!1,e["writing-mode"]=!1,e["z-index"]=!1,e}function QRe(e,t,n){}function kRe(e,t,n){}var CRe=/javascript\s*\:/img;function ARe(e,t){return CRe.test(t)?"":t}Nu.whiteList=PY(),Nu.getDefaultWhiteList=PY,Nu.onAttr=QRe,Nu.onIgnoreAttr=kRe,Nu.safeAttrValue=ARe;var IRe={indexOf:function(e,t){var n,r;if(Array.prototype.indexOf)return e.indexOf(t);for(n=0,r=e.length;n/g,GRe=/"/g,ZRe=/"/g,HRe=/&#([a-zA-Z0-9]*);?/gim,KRe=/:?/gim,JRe=/&newline;?/gim,Sy=/((j\s*a\s*v\s*a|v\s*b|l\s*i\s*v\s*e)\s*s\s*c\s*r\s*i\s*p\s*t\s*|m\s*o\s*c\s*h\s*a):/gi,IY=/e\s*x\s*p\s*r\s*e\s*s\s*s\s*i\s*o\s*n\s*\(.*/gi,DY=/u\s*r\s*l\s*\(.*/gi;function NY(e){return e.replace(GRe,""")}function MY(e){return e.replace(ZRe,'"')}function LY(e){return e.replace(HRe,function(n,r){return r[0]==="x"||r[0]==="X"?String.fromCharCode(parseInt(r.substr(1),16)):String.fromCharCode(parseInt(r,10))})}function UY(e){return e.replace(KRe,":").replace(JRe," ")}function XY(e){for(var t="",n=0,r=e.length;n",r);if(i===-1)break;n=i+3}return t}function rQe(e){var t=e.split("");return t=t.filter(function(n){var r=n.charCodeAt(0);return r===127?!1:r<=31?r===10||r===13:!0}),t.join("")}Mn.whiteList=kY(),Mn.getDefaultWhiteList=kY,Mn.onTag=BRe,Mn.onIgnoreTag=FRe,Mn.onTagAttr=WRe,Mn.onIgnoreTagAttr=VRe,Mn.safeAttrValue=YRe,Mn.escapeHtml=AY,Mn.escapeQuote=NY,Mn.unescapeQuote=MY,Mn.escapeHtmlEntities=LY,Mn.escapeDangerHtml5Entities=UY,Mn.clearNonPrintableCharacter=XY,Mn.friendlyAttrValue=zY,Mn.escapeAttrValue=BY,Mn.onIgnoreTagStripAll=eQe,Mn.StripTagBody=tQe,Mn.stripCommentTag=nQe,Mn.stripBlankChar=rQe,Mn.attributeWrapSign='"',Mn.cssFilter=CY,Mn.getDefaultCSSWhiteList=zRe;var Ey={},gc=lQ;function iQe(e){var t=gc.spaceIndex(e),n;return t===-1?n=e.slice(1,-1):n=e.slice(1,t+1),n=gc.trim(n).toLowerCase(),n.slice(0,1)==="/"&&(n=n.slice(1)),n.slice(-1)==="/"&&(n=n.slice(0,-1)),n}function aQe(e){return e.slice(0,2)===""||s===l-1){r+=n(e.slice(i,a)),u=e.slice(a,s+1),c=iQe(u),r+=t(a,r.length,c,u,aQe(u)),i=s+1,a=!1;continue}if(d==='"'||d==="'")for(var O=1,f=e.charAt(s-O);f.trim()===""||f==="=";){if(f==="="){o=d;continue e}f=e.charAt(s-++O)}}else if(d===o){o=!1;continue}}return i0;t--){var n=e[t];if(n!==" ")return n==="="?t:-1}}function OQe(e){return e[0]==='"'&&e[e.length-1]==='"'||e[0]==="'"&&e[e.length-1]==="'"}function FY(e){return OQe(e)?e.substr(1,e.length-2):e}Ey.parseTag=oQe,Ey.parseAttr=lQe;var fQe=sQ.FilterCSS,Xa=Mn,WY=Ey,pQe=WY.parseTag,hQe=WY.parseAttr,Ty=lQ;function wy(e){return e==null}function mQe(e){var t=Ty.spaceIndex(e);if(t===-1)return{html:"",closing:e[e.length-2]==="/"};e=Ty.trim(e.slice(t+1,-1));var n=e[e.length-1]==="/";return n&&(e=Ty.trim(e.slice(0,-1))),{html:e,closing:n}}function gQe(e){var t={};for(var n in e)t[n]=e[n];return t}function _Qe(e){var t={};for(var n in e)Array.isArray(e[n])?t[n.toLowerCase()]=e[n].map(function(r){return r.toLowerCase()}):t[n.toLowerCase()]=e[n];return t}function VY(e){e=gQe(e||{}),e.stripIgnoreTag&&(e.onIgnoreTag&&console.error('Notes: cannot use these two options "stripIgnoreTag" and "onIgnoreTag" at the same time'),e.onIgnoreTag=Xa.onIgnoreTagStripAll),e.whiteList||e.allowList?e.whiteList=_Qe(e.whiteList||e.allowList):e.whiteList=Xa.whiteList,this.attributeWrapSign=e.singleQuotedAttributeValue===!0?"'":Xa.attributeWrapSign,e.onTag=e.onTag||Xa.onTag,e.onTagAttr=e.onTagAttr||Xa.onTagAttr,e.onIgnoreTag=e.onIgnoreTag||Xa.onIgnoreTag,e.onIgnoreTagAttr=e.onIgnoreTagAttr||Xa.onIgnoreTagAttr,e.safeAttrValue=e.safeAttrValue||Xa.safeAttrValue,e.escapeHtml=e.escapeHtml||Xa.escapeHtml,this.options=e,e.css===!1?this.cssFilter=!1:(e.css=e.css||{},this.cssFilter=new fQe(e.css))}VY.prototype.process=function(e){if(e=e||"",e=e.toString(),!e)return"";var t=this,n=t.options,r=n.whiteList,i=n.onTag,a=n.onIgnoreTag,o=n.onTagAttr,s=n.onIgnoreTagAttr,l=n.safeAttrValue,c=n.escapeHtml,u=t.attributeWrapSign,d=t.cssFilter;n.stripBlankChar&&(e=Xa.stripBlankChar(e)),n.allowCommentTag||(e=Xa.stripCommentTag(e));var O=!1;n.stripIgnoreTagBody&&(O=Xa.StripTagBody(n.stripIgnoreTagBody,a),a=O.onIgnoreTag);var f=pQe(e,function(p,h,m,g,_){var b={sourcePosition:p,position:h,isClosing:_,isWhite:Object.prototype.hasOwnProperty.call(r,m)},y=i(m,g,b);if(!wy(y))return y;if(b.isWhite){if(b.isClosing)return"";var v=mQe(g),E=r[m],w=hQe(v.html,function(T,S){var x=Ty.indexOf(E,T)!==-1,$=o(m,T,S,x);return wy($)?x?(S=l(m,T,S,d),S?T+"="+u+S+u:T):($=s(m,T,S,x),wy($)?void 0:$):$});return g="<"+m,w&&(g+=" "+w),v.closing&&(g+=" /"),g+=">",g}else return y=a(m,g,b),wy(y)?c(g):y},c);return O&&(f=O.remove(f)),f};var bQe=VY;(function(e,t){var n=Mn,r=Ey,i=bQe;function a(s,l){var c=new i(l);return c.process(s)}t=e.exports=a,t.filterXSS=a,t.FilterXSS=i,function(){for(var s in n)t[s]=n[s];for(var l in r)t[l]=r[l]}(),typeof window<"u"&&(window.filterXSS=e.exports);function o(){return typeof self<"u"&&typeof DedicatedWorkerGlobalScope<"u"&&self instanceof DedicatedWorkerGlobalScope}o()&&(self.filterXSS=e.exports)})($Y,$Y.exports);const yQe={class:"relative w-4 h-4 cursor-pointer"},vQe={class:"relative w-4 h-4"},SQe=20*1024*1024,EQe=3,TQe=dp({__name:"Index2",props:{editorId:String,modelValue:String,modelModifiers:Object,autoDetectCode:{type:Boolean,default:!0}},emits:["update:modelValue","isUploading"],setup(e,{emit:t}){const n=["r","q","w","n","m","s","o","g",",","=","+","-",".","p","c","b","m","`","f","Enter","Backspace"],r=["bold","italic","underline","title","-","quote","code","table",1,"-","mermaid","katex","-","=","preview",0],i=xe(null),a=xe(null),o=xe(!1),s=()=>{o.value=!o.value,o.value?(T0.request(),document.querySelectorAll('[role="dialog"]').forEach(y=>y.style.display="none"),document.querySelector("body").style["pointer-events"]="auto"):(T0.exit(),document.querySelectorAll('[role="dialog"]').forEach(y=>y.style.display="block"),document.querySelector("body").style["pointer-events"]="none")},c=xe(e.modelValue),u=t,d=()=>{u("update:modelValue",c)},O=y=>{n.includes(y.key)&&y.stopPropagation()},f=y=>{document.addEventListener("keydown",O,!0)},p=y=>{document.removeEventListener("keydown",O,!0)},h=["image/jpeg","image/png","image/gif","image/webp"],m=async(y,v=0)=>{var E;try{const w=await nce(y);if(!((E=w.data)!=null&&E.url))throw new Error("Upload response missing URL");return w.data.url}catch(w){if(console.error(`Upload attempt ${v+1} failed:`,w),vsetTimeout(T,1e3*(v+1))),m(y,v+1);throw w}},g=async y=>{b([y.target.files[0]],v=>{v.forEach(E=>{i.value.insert(()=>({targetValue:`![image](${E})`,select:!1,deviationStart:0,deviationEnd:0})),c.value+=`![image](${E})`,d()})})},_=async y=>{b([y.target.files[0]],v=>{v.forEach(E=>{a.value.insert(()=>({targetValue:`![image](${E})`,select:!1,deviationStart:0,deviationEnd:0})),c.value+=`![image](${E})`,d()})})},b=async(y,v)=>{if(y.filter(T=>!h.includes(T.type)).length>0){Ut.warning("Only image files allowed (jpg, png, gif, webp)");return}if(y.filter(T=>T.size>SQe).length>0){Ut.warning("Image size cannot exceed 20MB");return}try{u("isUploading",!0);const T=[];for(let S=0;S(fe(),qe(Pt,null,[te(D(Mh),{editorId:e.editorId,modelValue:c.value,"onUpdate:modelValue":v[0]||(v[0]=E=>c.value=E),theme:"dark",toolbars:r,ref_key:"editorRef",ref:i,autoDetectCode:!0,language:"en-US",preview:!1,onInput:d,style:{height:"200px"},onOnUploadImg:b,onOnFocus:f,onOnBlur:p},{defToolbars:ce(()=>[te(D(hc),{title:"fullscreen",onOnClick:s},{trigger:ce(()=>[te(D(IN),{class:"w-4 h-4 mt-1"})]),_:1}),te(D(hc),{title:"image"},{trigger:ce(()=>[$e("div",yQe,[$e("input",{onChange:g,type:"file",class:"absolute w-4 h-4 left-0 top-0 cursor-pointer opacity-0"},null,32),te(D(AN),{class:"w-4 h-4 cursor-pointer"})])]),_:1})]),_:1},8,["editorId","modelValue"]),o.value?(fe(),Se(gd,{key:0,to:"body"},[te(D(Mh),{modelValue:c.value,"onUpdate:modelValue":v[1]||(v[1]=E=>c.value=E),theme:"dark",autoDetectCode:!0,editorId:`full-${e.editorId}`,toolbars:r,ref_key:"editorRefFull",ref:a,language:"en-US",pageFullscreen:!0,class:"fixed top-0 left-0 w-[100vw] h-[100vh] z-12000",onInput:d,onOnUploadImg:b,onOnFocus:f,onOnBlur:p},{defToolbars:ce(()=>[te(D(hc),{title:"fullscreen",onOnClick:s},{trigger:ce(()=>[te(D(IN),{class:"w-4 h-4 mt-1"})]),_:1}),te(D(hc),{title:"image"},{trigger:ce(()=>[$e("div",vQe,[$e("input",{onChange:_,type:"file",class:"absolute w-4 h-4 left-0 top-0 cursor-pointer opacity-0"},null,32),te(D(AN),{class:"w-4 h-4"})])]),_:1})]),_:1},8,["modelValue","editorId"])])):kt("",!0)],64))}},[["__scopeId","data-v-071fa62a"]]),wQe={class:"px-6 pb-6"},xQe={class:"bg-[#353535] z-1 px-6 py-4 w-full rounded-tl-lg rounded-tr-lg custom-shadow border-t-[1px] flex justify-between relative"},$Qe={key:0},PQe={key:1},RQe={class:"bg-[#353535] px-6 pb-4"},QQe={class:"flex items-center space-x-2 mt-2"},kQe={class:"flex h-28 items-center justify-end relative"},CQe={key:0,class:"absolute top-2 left-1 text-xs"},AQe={key:1,class:"flex-1"},IQe={class:"text-center pt-2"},DQe={key:0,class:"pl-2"},NQe={class:"bg-[#353535] px-6 w-full h-14 rounded-tl-lg rounded-tr-lg custom-shadow border-t-[1px] flex justify-between items-center -mt-4"},MQe={key:0,class:"z-50 w-full h-full absolute left-0 top-0"},LQe=ve({__name:"index",setup(e){const t=lp(),n=su(),r=xe(!0),i=xe([{value:"",label:""}]),a=xe([{value:"",label:""}]),o=xe({...n.modelDetail}),s=xe(-1),l=xe(!1),c=S=>{s.value=S,r.value&&(r.value=!1)},u=Ie(()=>o.value.versions.map(x=>x.progress).some((x,$)=>x!==100&&o.value.versions[$].file_upload_id));function d(S,x){o.value.versions&&(o.value.versions[x].public=S)}let O;async function f(S){if(!await t_({title:"Are you sure you want to delete this version?",desc:"This action cannot be undone.",cancel:"No, Keep It",continue:"Yes, Delete It",z:"z-9000"}))return;const $={...o.value};s.value===$.versions.length-1&&(s.value=Number(s.value)-1),$.versions=$.versions||[],$.versions.splice(S,1),n.setModelDetail($),$.versions.length===1&&(s.value=0),$.versions.length===0&&(r.value=!0)}function p(){const S={...o.value};S.versions=S.versions||[],S.versions.push({version:"",base_model:"",intro:"",public:!1,filePath:"",sign:"",path:""}),n.setModelDetail(S),r.value=!1,s.value=S.versions.length-1}function h(){if(!o.value.name){Ut.error("Please enter the model name"),o.value.nameError=!0;return}if(!o.value.type){Ut.error("Please select the model type"),o.value.typeError=!0;return}o.value.versions.length?(s.value=0,r.value=!1):p()}function m(){const S={...o.value};S.versions=S.versions||[];for(let x=0;xx.version&&x.base_model&&x.sign)}const g=(S,x)=>{o.value.versions[x].progress=S},_=(S,x)=>{o.value.versions[x].path=S},b=S=>{o.value.versions[S].filePathError=!1},y=(S,x)=>{o.value.versions[x].sign=S.sha256sum,o.value.versions[x].filePathError=!1},v=S=>{o.value.versions[S].progress&&delete o.value.versions[S].progress},E=(S,x)=>{S.speed&&(o.value.versions[x].speed=S.speed),S.fileName&&(o.value.versions[x].fileName=S.fileName)};async function w(){if(!m())return;l.value=!0,setTimeout(()=>{l.value=!1},5e3);const S={...o.value};S.versions.forEach(x=>{delete x.baseModelError,delete x.filePath,delete x.filePathError,delete x.versionError,delete x.speed,delete x.fileName}),S.id?await oce(S):await ace(S),Ut.success("Model published successfully"),T()}const T=()=>{n.setDialogStatus(!1,0),n.clearModelDetail(),r.value=!0,l.value=!1,n.uploadModelDone()};return Be(()=>t.socketMessage,S=>{if(S.type=="progress"){const x=o.value.versions.findIndex($=>$.file_upload_id==S.data.upload_id);o.value.versions[x].progress=Number(S.data.progress.replace("%",""))}if(S.type=="status"&&S.data.status=="finish"){const x=o.value.versions.findIndex($=>$.file_upload_id==S.data.upload_id);o.value.versions[x]&&(o.value.versions[x].path=S.data.model_files[0].path,o.value.versions[x].sign=S.data.model_files[0].sign)}if(S.type=="interrupted"){Ut.success("Upload interrupted");const x=o.value.versions.findIndex($=>$.file_upload_id==S.data.upload_id);delete o.value.versions[x].progress,o.value.versions[x].filePath=""}if(S.type=="error"){Ut.error(S.data.message);const x=o.value.versions.findIndex($=>$.file_upload_id==S.data.upload_id);delete o.value.versions[x].progress,o.value.versions[x].filePath=""}if(S.type=="prepared"&&O.close(),S.type==="errors"&&S.data&&S.data.code===500101){O.close(),Ut.error(S.data.message);const x=o.value.versions.findIndex($=>$.file_upload_id==S.data.data.upload_id);o.value.versions[x].progress&&delete o.value.versions[x].progress,o.value.versions[x].filePath=""}},{deep:!0}),Be(()=>n.modelDetail,S=>{o.value=S},{deep:!0}),Be(()=>n.showVersionId,S=>{const x=o.value.versions.findIndex($=>$.id==S);setTimeout(()=>{s.value=x}),x!=-1&&(r.value=!1)},{deep:!0}),ht(async()=>{const S=await b2();i.value=S.data;const x=await _2();a.value=x.data}),(S,x)=>(fe(),qe(Pt,null,[$e("div",{onClick:x[0]||(x[0]=$=>D(n).setDialogStatus(!0)),class:"flex items-center hover:bg-[#4A238E] cursor-pointer relative px-3"},x[7]||(x[7]=[$e("svg",{xmlns:"http://www.w3.org/2000/svg",width:"1rem",height:"1rem",viewBox:"0 0 24 24"},[$e("path",{fill:"none",stroke:"#ddd","stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"1.5",d:"M21 16.008V7.99a1.98 1.98 0 0 0-1-1.717l-7-4.008a2.02 2.02 0 0 0-2 0L4 6.273c-.619.355-1 1.01-1 1.718v8.018c0 .709.381 1.363 1 1.717l7 4.008a2.02 2.02 0 0 0 2 0l7-4.008c.619-.355 1-1.01 1-1.718M12 22V12m0 0l8.73-5.04m-17.46 0L12 12"})],-1),$e("span",{class:"block leading h-full leading-8 text-sm"},"Publish",-1)])),D(n).showDialog?(fe(),Se(n_,{key:0,open:D(n).showDialog,"onUpdate:open":x[6]||(x[6]=$=>D(n).showDialog=$),onOnClose:T,class:"px-0 overflow-hidden pb-0 z-9000",layoutClass:"z-9000",contentClass:"custom-scrollbar max-h-[80vh] overflow-y-auto w-full rounded-tl-lg rounded-tr-lg custom-shadow"},ZK({title:ce(()=>[$e("span",{class:"px-6 cursor-pointer",onClick:x[1]||(x[1]=$=>{s.value=-1,r.value=!0})},"Publish a Model")]),default:ce(()=>[Ja($e("div",wQe,[te(ou,{label:"Model Name"},{default:ce(()=>[te(D(cp),{onChange:x[2]||(x[2]=$=>o.value.nameError=!1),class:xt({"border-red-500":o.value.nameError}),type:"text",placeholder:"Enter Model Name","model-value":o.value.name,"onUpdate:modelValue":x[3]||(x[3]=$=>o.value.name=$)},null,8,["class","model-value"])]),_:1}),te(ou,{label:"Model Type"},{default:ce(()=>[te(u2,{"onUpdate:open":x[4]||(x[4]=$=>o.value.typeError=!1),class:xt({"border-red-500":o.value.typeError}),"model-value":o.value.type,"onUpdate:modelValue":x[5]||(x[5]=$=>o.value.type=$),placeholder:"Select Model Type"},{default:ce(()=>[(fe(!0),qe(Pt,null,Oi(i.value,($,Q)=>(fe(),Se(D(l2),{key:Q,value:$.value},{default:ce(()=>[ot(Ot($.label),1)]),_:2},1032,["value"]))),128))]),_:1},8,["class","model-value"])]),_:1}),te(D(Ur),{class:"w-full mt-3",onClick:h},{default:ce(()=>x[8]||(x[8]=[ot("Next Step")])),_:1})],512),[[Ds,r.value]]),te(Tle,{multiple:!0,activeIndex:s.value},{default:ce(()=>[(fe(!0),qe(Pt,null,Oi(o.value.versions,($,Q)=>(fe(),Se(wle,{key:Q,index:Q,onToggle:c},{title:ce(()=>[$e("div",xQe,[s.value!==Q&&$.version?(fe(),qe("span",$Qe,Ot($.version),1)):(fe(),qe("span",PQe,"Add Version")),o.value.versions.length!==1?(fe(),Se(D(Eoe),{key:2,class:"w-4 h-4",onClickCapture:Sr(k=>f(Q),["stop"])},null,8,["onClickCapture"])):kt("",!0),$.progress&&s.value&&s.value!==Q?(fe(),Se(D(c2),{key:3,"model-value":$.progress,class:"absolute w-full bottom-0 left-0 h-1"},null,8,["model-value"])):kt("",!0)])]),default:ce(()=>[$e("div",RQe,[te(ou,{label:"Version Name"},{default:ce(()=>[te(D(cp),{onChange:k=>$.versionError=!1,class:xt({"border-red-500":$.versionError}),type:"text",placeholder:"Version Name","model-value":$.version,"onUpdate:modelValue":k=>$.version=k},null,8,["onChange","class","model-value","onUpdate:modelValue"])]),_:2},1024),te(ou,{label:"Base Model"},{default:ce(()=>[te(u2,{"onUpdate:open":k=>$.baseModelError=!1,class:xt({"border-red-500":$.baseModelError}),"model-value":$.base_model,"onUpdate:modelValue":k=>$.base_model=k,placeholder:"Select Base Model"},{default:ce(()=>[(fe(!0),qe(Pt,null,Oi(a.value,(k,P)=>(fe(),Se(D(l2),{key:P,value:k.value},{default:ce(()=>[ot(Ot(k.label),1)]),_:2},1032,["value"]))),128))]),_:2},1032,["onUpdate:open","class","model-value","onUpdate:modelValue"])]),_:2},1024),te(ou,{label:"Introduction"},{default:ce(()=>[te(TQe,{modelValue:$.intro,"onUpdate:modelValue":k=>$.intro=k,modelModifiers:{modelValue:!0},editorId:`myeditor${Q}`},null,8,["modelValue","onUpdate:modelValue","editorId"])]),_:2},1024),te(ou,{label:""},{default:ce(()=>[$e("div",QQe,[te(D(Ole),{id:"airplane-mode",checked:$.public,"onUpdate:checked":[k=>$.public=k,k=>{d(k,Q)}]},null,8,["checked","onUpdate:checked"]),te(D(dle),{for:"airplane-mode"},{default:ce(()=>x[9]||(x[9]=[ot("Publicly Visible")])),_:1})])]),_:2},1024),Ja(te(ou,{label:"File"},{default:ce(()=>[$e("div",kQe,[$.progress&&$.fileName?(fe(),qe("p",CQe,Ot($.fileName),1)):kt("",!0),$.progress?(fe(),qe("div",AQe,[te(D(c2),{"model-value":$.progress,class:"mt-4 h-3"},null,8,["model-value"]),$e("p",IQe,[ot(Ot($.progress)+"% Uploaded ",1),$.speed?(fe(),qe("span",DQe,"Speed: "+Ot($.speed),1)):kt("",!0)])])):kt("",!0),te(fce,{parallel:1,ref_for:!0,ref:$.ref,chunkSize:1,class:xt({"border-red-500":$.filePathError}),onPath:k=>_(k,Q),onStart:()=>b(Q),onSuccess:k=>y(k,Q),onError:()=>v(Q),onUploadInfo:k=>E(k,Q),onProgress:k=>g(k,Q)},null,8,["class","onPath","onStart","onSuccess","onError","onUploadInfo","onProgress"])])]),_:2},1536),[[Ds,!$.showUpload]])])]),_:2},1032,["index"]))),128))]),_:1},8,["activeIndex"]),l.value?(fe(),qe("div",MQe)):kt("",!0)]),_:2},[r.value?void 0:{name:"foot",fn:ce(()=>[$e("div",NQe,[te(D(Ur),{variant:"outline",class:"",onClick:p},{default:ce(()=>x[10]||(x[10]=[ot("Add Version")])),_:1}),te(D(Ur),{disabled:u.value,onClick:w},{default:ce(()=>x[11]||(x[11]=[ot("Publish")])),_:1},8,["disabled"])])]),key:"0"}]),1032,["open"])):kt("",!0)],64))}}),UQe=ve({__name:"index",setup(e){const t=xe({"Remote Folders":"1",Upload:"2"});return fetch("api/bizyair/news",{method:"GET"}).then(n=>n.json()).then(n=>{t.value=n}),(n,r)=>(fe(),Se(NN,{show_cases:t.value,buttonText:"News",icon:"book-open",isJson:!0},{default:ce(()=>r[0]||(r[0]=[$e("svg",{xmlns:"http://www.w3.org/2000/svg",width:"1rem",height:"1rem",viewBox:"0 0 32 32"},[$e("path",{fill:"#ddd",d:"M11 23a1 1 0 1 0 0 2h10a1 1 0 1 0 0-2zm-1-3a1 1 0 0 1 1-1h10a1 1 0 1 1 0 2H11a1 1 0 0 1-1-1m1-5a1 1 0 1 0 0 2h10a1 1 0 1 0 0-2zM5 5a3 3 0 0 1 3-3h10.172a3 3 0 0 1 2.12.879l5.83 5.828A3 3 0 0 1 27 10.828V27a3 3 0 0 1-3 3H8a3 3 0 0 1-3-3zm3-1a1 1 0 0 0-1 1v22a1 1 0 0 0 1 1h16a1 1 0 0 0 1-1V12h-5a3 3 0 0 1-3-3V4zm12 6h4.586L19 4.414V9a1 1 0 0 0 1 1"})],-1)])),_:1},8,["show_cases"]))}}),XQe={class:"comfy-modal-content-sml"},zQe={class:"py-2"},BQe=ve({__name:"apiKeyDialog",setup(e){const t=lp(),n=xe(""),r=xe(!1),i=async c=>{const f=window.open("https://account.siliconflow.cn/oauth?client_id=SFaJLLq0y6CAMoyDm81aMu","oauthPopup","width=600,height=600");window.addEventListener("message",p=>{p.data.length>0&&p.data[0].secretKey!==void 0&&(c(p.data[0].secretKey),f&&f.close())})};function a(){r.value=!1}async function o(){if(!n.value)return r.value=!0,!1;const c=await hse(`api_key=${encodeURIComponent(n.value)}`);c.ok?(Ut("API Key set successfully!"),t.handleApiKeyDialog(!1),t.loginRefresh()):Ut.error(`Failed to set API Key: ${await c.text()}`)}function s(){t.handleApiKeyDialog(!1),n.value="",r.value=!1}function l(){i(c=>{n.value=c})}return(c,u)=>(fe(),Se(n_,{open:D(t).showApiKeyDialog,"onUpdate:open":u[1]||(u[1]=d=>D(t).showApiKeyDialog=d),layoutClass:"z-9000",class:"max-w-[680px] z-9000",onOnClose:u[2]||(u[2]=d=>D(t).handleApiKeyDialog(!1))},{title:ce(()=>u[3]||(u[3]=[ot("Set API Key")])),foot:ce(()=>[te(D(Ur),{type:"submit",onClick:o},{default:ce(()=>u[8]||(u[8]=[ot("Submit")])),_:1}),te(D(Ur),{variant:"outline",onClick:s},{default:ce(()=>u[9]||(u[9]=[ot("Close")])),_:1})]),default:ce(()=>[$e("div",XQe,[te(D(cp),{modelValue:n.value,"onUpdate:modelValue":u[0]||(u[0]=d=>n.value=d),type:"password",placeholder:"API Key",class:xt([{"border-red-500":r.value}]),onInput:a},null,8,["modelValue","class"]),$e("p",zQe,[u[4]||(u[4]=ot(" Please ")),$e("a",{class:"underline",href:"###",onClick:Sr(l,["prevent"])},"click to login"),u[5]||(u[5]=ot(" and autofill the key, "))]),u[6]||(u[6]=$e("p",{class:"py-2"},[ot(" or visit "),$e("a",{class:"underline",href:"https://cloud.siliconflow.cn",target:"_blank"},"https://cloud.siliconflow.cn"),ot(" to get your key and input manually. ")],-1)),u[7]||(u[7]=$e("p",{class:"py-2"},[ot(" Setting the API Key signifies agreement to the "),$e("a",{class:"underline",href:"https://docs.siliconflow.cn/docs/user-agreement",target:"_blank"},"User Agreement"),ot(" and "),$e("a",{class:"underline",href:"https://docs.siliconflow.cn/docs/privacy-policy",target:"_blank"},"Privacy Policy.")],-1))])]),_:1},8,["open"]))}}),FQe={class:"shadcn-root flex w-full"},WQe=ve({__name:"App",setup(e){const t=lp();return t.loginRefresh(),t.sendSocket(),(n,r)=>(fe(),qe("div",FQe,[te(Moe),D(t).isLogin?(fe(),Se(nle,{key:0})):(fe(),Se(Tse,{key:1})),te(LQe),te(UQe),te(BQe)]))}}),YY=ve({__name:"Tabs",props:{defaultValue:{},orientation:{},dir:{},activationMode:{},modelValue:{},asChild:{type:Boolean},as:{}},emits:["update:modelValue"],setup(e,{emit:t}){const i=nn(e,t);return(a,o)=>(fe(),Se(D(vae),Nt(Lt(D(i))),{default:ce(()=>[we(a.$slots,"default")]),_:3},16))}}),VQe=ve({__name:"TabsContent",props:{value:{},forceMount:{type:Boolean},asChild:{type:Boolean},as:{},class:{}},setup(e){const t=e,n=Ie(()=>{const{class:r,...i}=t;return i});return(r,i)=>(fe(),Se(D(Eae),Ue({class:D(dt)("mt-2 ring-offset-background focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2",t.class)},n.value),{default:ce(()=>[we(r.$slots,"default")]),_:3},16,["class"]))}}),jY=ve({__name:"TabsList",props:{loop:{type:Boolean},asChild:{type:Boolean},as:{},class:{}},setup(e){const t=e,n=Ie(()=>{const{class:r,...i}=t;return i});return(r,i)=>(fe(),Se(D(Sae),Ue(n.value,{class:D(dt)("inline-flex items-center justify-center rounded-md bg-muted p-1 text-muted-foreground",t.class)}),{default:ce(()=>[we(r.$slots,"default")]),_:3},16,["class"]))}}),YQe={class:"truncate"},qY=ve({__name:"TabsTrigger",props:{value:{},disabled:{type:Boolean},asChild:{type:Boolean},as:{},class:{}},setup(e){const t=e,n=Ie(()=>{const{class:i,...a}=t;return a}),r=Gr(n);return(i,a)=>(fe(),Se(D(Tae),Ue(D(r),{class:D(dt)("inline-flex items-center justify-center whitespace-nowrap rounded-sm px-3 py-1.5 text-sm font-medium ring-offset-background transition-all focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50 data-[state=active]:bg-background data-[state=active]:text-foreground data-[state=active]:shadow-sm",t.class)}),{default:ce(()=>[$e("span",YQe,[we(i.$slots,"default")])]),_:3},16,["class"]))}}),cQ=ve({__name:"Badge",props:{variant:{},class:{}},setup(e){const t=e;return(n,r)=>(fe(),qe("div",{class:xt(D(dt)(D(jQe)({variant:n.variant}),t.class))},[we(n.$slots,"default")],2))}}),jQe=g0("inline-flex items-center rounded-full border px-2.5 py-0.5 text-xs font-semibold transition-colors focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2",{variants:{variant:{default:"border-transparent bg-primary text-primary-foreground hover:bg-primary/80",secondary:"border-transparent bg-secondary text-secondary-foreground hover:bg-secondary/80",destructive:"border-transparent bg-destructive text-destructive-foreground hover:bg-destructive/80",outline:"text-foreground"}},defaultVariants:{variant:"default"}}),xy=ve({__name:"Popover",props:{defaultOpen:{type:Boolean},open:{type:Boolean},modal:{type:Boolean}},emits:["update:open"],setup(e,{emit:t}){const i=nn(e,t);return(a,o)=>(fe(),Se(D(Oie),Nt(Lt(D(i))),{default:ce(()=>[we(a.$slots,"default")]),_:3},16))}}),$y=ve({inheritAttrs:!1,__name:"PopoverContent",props:{forceMount:{type:Boolean},trapFocus:{type:Boolean},side:{},sideOffset:{default:4},align:{default:"center"},alignOffset:{},avoidCollisions:{type:Boolean},collisionBoundary:{},collisionPadding:{},arrowPadding:{},sticky:{},hideWhenDetached:{type:Boolean},updatePositionStrategy:{},prioritizePosition:{type:Boolean},asChild:{type:Boolean},as:{},disableOutsidePointerEvents:{type:Boolean},class:{}},emits:["escapeKeyDown","pointerDownOutside","focusOutside","interactOutside","openAutoFocus","closeAutoFocus"],setup(e,{emit:t}){const n=e,r=t,i=Ie(()=>{const{class:o,...s}=n;return s}),a=nn(i,r);return(o,s)=>(fe(),Se(D(pie),null,{default:ce(()=>[te(D(gie),Ue({...D(a),...o.$attrs},{class:D(dt)("z-50 w-72 rounded-md border bg-popover p-4 text-popover-foreground shadow-md outline-none data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",n.class)}),{default:ce(()=>[we(o.$slots,"default")]),_:3},16,["class"])]),_:3}))}}),Py=ve({__name:"PopoverTrigger",props:{asChild:{type:Boolean},as:{}},setup(e){const t=e;return(n,r)=>(fe(),Se(D(fie),Nt(Lt(t)),{default:ce(()=>[we(n.$slots,"default")]),_:3},16))}}),Ry=ve({__name:"Command",props:{modelValue:{default:""},defaultValue:{},open:{type:Boolean,default:!0},defaultOpen:{type:Boolean},searchTerm:{},selectedValue:{},multiple:{type:Boolean},disabled:{type:Boolean},name:{},dir:{},filterFunction:{},displayValue:{},resetSearchTermOnBlur:{type:Boolean},asChild:{type:Boolean},as:{},class:{}},emits:["update:modelValue","update:open","update:searchTerm","update:selectedValue"],setup(e,{emit:t}){const n=e,r=t,i=Ie(()=>{const{class:o,...s}=n;return s}),a=nn(i,r);return(o,s)=>(fe(),Se(D(cre),Ue(D(a),{class:D(dt)("flex h-full w-full flex-col overflow-hidden rounded-md bg-popover text-popover-foreground",n.class)}),{default:ce(()=>[we(o.$slots,"default")]),_:3},16,["class"]))}}),Uh=ve({__name:"CommandGroup",props:{asChild:{type:Boolean},as:{},class:{},heading:{}},setup(e){const t=e,n=Ie(()=>{const{class:r,...i}=t;return i});return(r,i)=>(fe(),Se(D(dre),Ue(n.value,{class:D(dt)("overflow-hidden p-1 text-foreground [&_[cmdk-group-heading]]:px-2 [&_[cmdk-group-heading]]:py-1.5 [&_[cmdk-group-heading]]:text-xs [&_[cmdk-group-heading]]:font-medium [&_[cmdk-group-heading]]:text-muted-foreground",t.class)}),{default:ce(()=>[r.heading?(fe(),Se(D(Ore),{key:0,class:"px-2 py-1.5 text-xs font-medium text-muted-foreground"},{default:ce(()=>[ot(Ot(r.heading),1)]),_:1})):kt("",!0),we(r.$slots,"default")]),_:3},16,["class"]))}}),cl=ve({__name:"CommandItem",props:{value:{},disabled:{type:Boolean},asChild:{type:Boolean},as:{},class:{}},emits:["select"],setup(e,{emit:t}){const n=e,r=t,i=Ie(()=>{const{class:o,...s}=n;return s}),a=nn(i,r);return(o,s)=>(fe(),Se(D(_re),Ue(D(a),{class:D(dt)("relative flex cursor-default select-none items-center rounded-sm px-2 py-1.5 text-sm outline-none data-[highlighted]:bg-accent data-[highlighted]:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50",n.class)}),{default:ce(()=>[we(o.$slots,"default")]),_:3},16,["class"]))}}),qQe={role:"presentation"},Qy=ve({__name:"CommandList",props:{forceMount:{type:Boolean},position:{},bodyLock:{type:Boolean},dismissable:{type:Boolean,default:!1},side:{},sideOffset:{},align:{},alignOffset:{},avoidCollisions:{type:Boolean},collisionBoundary:{},collisionPadding:{},arrowPadding:{},sticky:{},hideWhenDetached:{type:Boolean},updatePositionStrategy:{},prioritizePosition:{type:Boolean},asChild:{type:Boolean},as:{},disableOutsidePointerEvents:{type:Boolean},class:{}},emits:["escapeKeyDown","pointerDownOutside","focusOutside","interactOutside"],setup(e,{emit:t}){const n=e,r=t,i=Ie(()=>{const{class:o,...s}=n;return s}),a=nn(i,r);return(o,s)=>(fe(),Se(D(hre),Ue(D(a),{class:D(dt)("max-h-[300px] overflow-y-auto overflow-x-hidden",n.class)}),{default:ce(()=>[$e("div",qQe,[we(o.$slots,"default")])]),_:3},16,["class"]))}}),uQ=ve({__name:"CommandSeparator",props:{asChild:{type:Boolean},as:{},class:{}},setup(e){const t=e,n=Ie(()=>{const{class:r,...i}=t;return i});return(r,i)=>(fe(),Se(D(bre),Ue(n.value,{class:D(dt)("-mx-1 h-px bg-border",t.class)}),{default:ce(()=>[we(r.$slots,"default")]),_:3},16,["class"]))}}),GQe={class:"flex space-x-2 mb-4"},ZQe={class:"relative flex-1"},HQe={class:"flex flex-wrap gap-2"},KQe={class:"flex flex-wrap gap-2"},JQe=ve({__name:"ModelFilterBar",props:{showSortPopover:{type:Boolean}},emits:["update:showSortPopover","fetchData"],setup(e,{emit:t}){const n=su(),r=xe([]),i=t,a=c=>{n.filterState.sort=c,i("fetchData"),i("update:showSortPopover",!1)},o=c=>{if(n.selectedBaseModels.length!==0)return;const u=[...n.filterState.model_types],d=u.indexOf(c);d===-1?u.push(c):u.splice(d,1),n.filterState.model_types=u,i("fetchData"),i("update:showSortPopover",!1)},s=c=>{const u=[...n.filterState.base_models],d=u.indexOf(c);d===-1?u.push(c):u.splice(d,1),n.filterState.base_models=u,i("fetchData"),i("update:showSortPopover",!1)},l=()=>{n.modelListPathParams.current=1,i("fetchData"),i("update:showSortPopover",!1)};return ht(async()=>{n.selectedBaseModels&&(r.value=[...n.selectedBaseModels])}),(c,u)=>{const d=GK("debounce");return fe(),qe("div",GQe,[$e("div",ZQe,[Ja(te(D(cp),{modelValue:D(n).filterState.keyword,"onUpdate:modelValue":u[0]||(u[0]=O=>D(n).filterState.keyword=O),placeholder:"Filter by name",class:"h-[44px] border border-[#9CA3AF] w-full bg-[#222] rounded-lg pr-8 pl-8"},null,8,["modelValue"]),[[d,l]]),u[5]||(u[5]=$e("span",{class:"absolute start-0 inset-y-0 flex items-center justify-center px-2"},[$e("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 16 16",fill:"none",class:"hover:brightness-150 transition-all duration-300"},[$e("path",{d:"M14 14L11.1333 11.1333M12.6667 7.33333C12.6667 10.2789 10.2789 12.6667 7.33333 12.6667C4.38781 12.6667 2 10.2789 2 7.33333C2 4.38781 4.38781 2 7.33333 2C10.2789 2 12.6667 4.38781 12.6667 7.33333Z",stroke:"#F9FAFB","stroke-linecap":"round","stroke-linejoin":"round"})])],-1))]),te(D(xy),{class:"bg-[#353535]",open:c.showSortPopover,"onUpdate:open":u[4]||(u[4]=O=>i("update:showSortPopover",O))},{default:ce(()=>[te(D(Py),{class:"bg-transparent"},{default:ce(()=>[te(D(Ur),{variant:"default",class:"w-[44px] h-[44px] hover:border-2 hover:border-white cursor-pointer group"},{default:ce(()=>u[6]||(u[6]=[$e("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 16 16",fill:"none"},[$e("path",{d:"M2 10.6667L4.66667 13.3334M4.66667 13.3334L7.33333 10.6667M4.66667 13.3334V2.66675M7.33333 2.66675H14M7.33333 5.33341H12M7.33333 8.00008H10",stroke:"#F9FAFB","stroke-linecap":"round","stroke-linejoin":"round"})],-1)])),_:1})]),_:1}),te(D($y),{side:"bottom",align:"end",class:"w-[150px] p-0 bg-[#353535] rounded-lg z-12000"},{default:ce(()=>[te(D(Ry),null,{default:ce(()=>[te(D(Qy),null,{default:ce(()=>[te(D(Uh),null,{default:ce(()=>[te(D(cl),{value:"recently",onClick:u[1]||(u[1]=O=>a("Recently")),class:xt(["px-2 py-1.5 text-[#F9FAFB] cursor-pointer [&:hover]:!bg-[#6D28D9] [&:hover]:!text-[#F9FAFB]",D(n).filterState.sort==="Recently"?"!bg-[#6D28D9] !text-[#F9FAFB]":""])},{default:ce(()=>u[7]||(u[7]=[ot(" Recently ")])),_:1},8,["class"]),["my","my_fork"].includes(D(n).mode)?kt("",!0):(fe(),Se(D(cl),{key:0,value:"most-forked",onClick:u[2]||(u[2]=O=>a("Most Forked")),class:xt(["px-2 py-1.5 text-[#F9FAFB] cursor-pointer [&:hover]:!bg-[#6D28D9] [&:hover]:!text-[#F9FAFB]",D(n).filterState.sort==="Most Forked"?"!bg-[#6D28D9] !text-[#F9FAFB]":""])},{default:ce(()=>u[8]||(u[8]=[ot(" Most Forked ")])),_:1},8,["class"])),["my","my_fork"].includes(D(n).mode)?kt("",!0):(fe(),Se(D(cl),{key:1,value:"most-used",onClick:u[3]||(u[3]=O=>a("Most Used")),class:xt(["px-2 py-1.5 text-[#F9FAFB] cursor-pointer [&:hover]:!bg-[#6D28D9] [&:hover]:!text-[#F9FAFB]",D(n).filterState.sort==="Most Used"?"!bg-[#6D28D9] !text-[#F9FAFB]":""])},{default:ce(()=>u[9]||(u[9]=[ot(" Most Used ")])),_:1},8,["class"]))]),_:1})]),_:1})]),_:1})]),_:1})]),_:1},8,["open"]),te(D(xy),null,{default:ce(()=>[te(D(Py),{class:"bg-transparent"},{default:ce(()=>[te(D(Ur),{variant:"default",class:"w-[44px] h-[44px] hover:border-2 hover:border-white cursor-pointer"},{default:ce(()=>u[10]||(u[10]=[$e("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 16 16",fill:"none",class:"mr-2"},[$e("path",{d:"M14.6666 2H1.33325L6.66658 8.30667V12.6667L9.33325 14V8.30667L14.6666 2Z",stroke:"#F9FAFB","stroke-linecap":"round","stroke-linejoin":"round"})],-1)])),_:1})]),_:1}),te(D($y),{side:"bottom",align:"end",class:"w-[200px] p-0 bg-[#222] rounded-lg z-12000"},{default:ce(()=>[te(D(Ry),null,{default:ce(()=>[te(D(Qy),null,{default:ce(()=>[te(D(Uh),null,{default:ce(()=>[u[11]||(u[11]=$e("div",{class:"p-2"},[$e("div",{class:"text-sm font-medium text-[#F9FAFB] mb-2"},"Model Types")],-1)),te(D(cl),{value:"model-types",class:"p-2"},{default:ce(()=>[$e("div",HQe,[(fe(!0),qe(Pt,null,Oi(D(n).modelTypes,O=>(fe(),Se(D(cQ),{variant:"secondary",key:O.value,onClick:f=>o(O.value),class:xt(["cursor-not-allowed hover:!bg-inherit",D(n).filterState.model_types.includes(O.value)?"bg-[#6D28D9] hover:!bg-[#6D28D9]":"bg-[#4E4E4E] hover:!bg-[#4E4E4E]"])},{default:ce(()=>[ot(Ot(O.label),1)]),_:2},1032,["onClick","class"]))),128))])]),_:1})]),_:1}),te(D(uQ)),te(D(Uh),null,{default:ce(()=>[u[12]||(u[12]=$e("div",{class:"p-2"},[$e("div",{class:"text-sm font-medium text-[#F9FAFB] mb-2"},"Base Models")],-1)),te(D(cl),{value:"base-models",class:"p-2"},{default:ce(()=>[$e("div",KQe,[(fe(!0),qe(Pt,null,Oi(D(n).baseModelTypes.filter(O=>{var f,p;return((f=D(n).selectedBaseModels)==null?void 0:f.length)===0||((p=D(n).selectedBaseModels)==null?void 0:p.includes(O.value))}),O=>(fe(),Se(D(cQ),{variant:"secondary",key:O.value,onClick:f=>s(O.value),class:xt(["cursor-pointer hover:!bg-inherit",D(n).filterState.base_models.includes(O.value)?"bg-[#6D28D9] hover:!bg-[#6D28D9]":"bg-[#4E4E4E] hover:!bg-[#4E4E4E]"])},{default:ce(()=>[ot(Ot(O.label),1)]),_:2},1032,["onClick","class"]))),128))])]),_:1})]),_:1})]),_:1})]),_:1})]),_:1})]),_:1})])}}}),eke=ve({__name:"PaginationEllipsis",props:{asChild:{type:Boolean},as:{},class:{}},setup(e){const t=e,n=Ie(()=>{const{class:r,...i}=t;return i});return(r,i)=>(fe(),Se(D(nie),Ue(n.value,{class:D(dt)("w-9 h-9 flex items-center justify-center",t.class)}),{default:ce(()=>[we(r.$slots,"default",{},()=>[te(D(yoe))])]),_:3},16,["class"]))}}),tke=ve({__name:"PaginationFirst",props:{asChild:{type:Boolean,default:!0},as:{},class:{}},setup(e){const t=e,n=Ie(()=>{const{class:r,...i}=t;return i});return(r,i)=>(fe(),Se(D(rie),Nt(Lt(n.value)),{default:ce(()=>[te(D(Ur),{class:xt(D(dt)("w-10 h-10 p-0",t.class)),variant:"outline"},{default:ce(()=>[we(r.$slots,"default",{},()=>[te(D(moe),{class:"h-4 w-4"})])]),_:3},8,["class"])]),_:3},16))}}),nke=ve({__name:"PaginationLast",props:{asChild:{type:Boolean,default:!0},as:{},class:{}},setup(e){const t=e,n=Ie(()=>{const{class:r,...i}=t;return i});return(r,i)=>(fe(),Se(D(iie),Nt(Lt(n.value)),{default:ce(()=>[te(D(Ur),{class:xt(D(dt)("w-10 h-10 p-0",t.class)),variant:"outline"},{default:ce(()=>[we(r.$slots,"default",{},()=>[te(D(goe),{class:"h-4 w-4"})])]),_:3},8,["class"])]),_:3},16))}}),rke=ve({__name:"PaginationNext",props:{asChild:{type:Boolean,default:!0},as:{},class:{}},setup(e){const t=e,n=Ie(()=>{const{class:r,...i}=t;return i});return(r,i)=>(fe(),Se(D(cie),Nt(Lt(n.value)),{default:ce(()=>[te(D(Ur),{class:xt(D(dt)("w-10 h-10 p-0",t.class)),variant:"outline"},{default:ce(()=>[we(r.$slots,"default",{},()=>[te(D(CN),{class:"h-4 w-4"})])]),_:3},8,["class"])]),_:3},16))}}),ike=ve({__name:"PaginationPrev",props:{asChild:{type:Boolean,default:!0},as:{},class:{}},setup(e){const t=e,n=Ie(()=>{const{class:r,...i}=t;return i});return(r,i)=>(fe(),Se(D(uie),Nt(Lt(n.value)),{default:ce(()=>[te(D(Ur),{class:xt(D(dt)("w-10 h-10 p-0",t.class)),variant:"outline"},{default:ce(()=>[we(r.$slots,"default",{},()=>[te(D(poe),{class:"h-4 w-4"})])]),_:3},8,["class"])]),_:3},16))}}),ake={key:0},oke=dp(ve({__name:"ModelPagination",setup(e){const t=su(),n=Ie(()=>t.modelListPathParams.total/t.modelListPathParams.page_size>1),r=i=>{t.updatePagination(i)};return(i,a)=>n.value?(fe(),qe("div",ake,[te(D(tie),{total:D(t).modelListPathParams.total,"items-per-page":D(t).modelListPathParams.page_size,"default-page":D(t).modelListPathParams.current,"sibling-count":1,"show-edges":"","onUpdate:page":r},{default:ce(({page:o})=>[te(D(sie),{class:"flex items-center gap-1"},{default:ce(({items:s})=>[te(D(tke),{class:"pagination-button"}),te(D(ike),{class:"pagination-button"}),(fe(!0),qe(Pt,null,Oi(s,(l,c)=>(fe(),qe(Pt,null,[l.type==="page"?(fe(),Se(D(lie),{key:c,value:l.value,"as-child":""},{default:ce(()=>[te(D(Ur),{class:"pagination-button page-button",variant:l.value===o?"default":"ghost"},{default:ce(()=>[ot(Ot(l.value),1)]),_:2},1032,["variant"])]),_:2},1032,["value"])):(fe(),Se(D(eke),{key:l.type,index:c,class:"pagination-button"},null,8,["index"]))],64))),256)),te(D(rke),{class:"pagination-button"}),te(D(nke),{class:"pagination-button"})]),_:2},1024)]),_:1},8,["total","items-per-page","default-page"])])):kt("",!0)}}),[["__scopeId","data-v-654ff384"]]),ske={class:"relative w-full overflow-auto"},lke=ve({__name:"Table",props:{class:{}},setup(e){const t=e;return(n,r)=>(fe(),qe("div",ske,[$e("table",{class:xt(D(dt)("w-full caption-bottom text-sm",t.class))},[we(n.$slots,"default")],2)]))}}),cke=ve({__name:"TableBody",props:{class:{}},setup(e){const t=e;return(n,r)=>(fe(),qe("tbody",{class:xt(D(dt)("[&_tr:last-child]:border-0",t.class))},[we(n.$slots,"default")],2))}}),Os=ve({__name:"TableCell",props:{class:{}},setup(e){const t=e;return(n,r)=>(fe(),qe("td",{class:xt(D(dt)("p-4 align-middle [&:has([role=checkbox])]:pr-0",t.class))},[we(n.$slots,"default")],2))}}),Xh=ve({__name:"TableRow",props:{class:{}},setup(e){const t=e;return(n,r)=>(fe(),qe("tr",{class:xt(D(dt)("border-b transition-colors hover:bg-muted/50 data-[state=selected]:bg-muted",t.class))},[we(n.$slots,"default")],2))}}),ky=ve({__name:"TableHead",props:{class:{}},setup(e){const t=e;return(n,r)=>(fe(),qe("th",{class:xt(D(dt)("h-12 px-4 text-left align-middle font-medium text-muted-foreground [&:has([role=checkbox])]:pr-0",t.class))},[we(n.$slots,"default")],2))}}),uke=ve({__name:"TableHeader",props:{class:{}},setup(e){const t=e;return(n,r)=>(fe(),qe("thead",{class:xt(D(dt)("[&_tr]:border-b",t.class))},[we(n.$slots,"default")],2))}}),GY=ve({__name:"ScrollBar",props:{orientation:{default:"vertical"},forceMount:{type:Boolean},asChild:{type:Boolean},as:{},class:{}},setup(e){const t=e,n=Ie(()=>{const{class:r,...i}=t;return i});return(r,i)=>(fe(),Se(D(Die),Ue(n.value,{class:D(dt)("flex touch-none select-none transition-colors",r.orientation==="vertical"&&"h-full w-2.5 border-l border-l-transparent p-px",r.orientation==="horizontal"&&"h-2.5 flex-col border-t border-t-transparent p-px",t.class)}),{default:ce(()=>[te(D(Nie),{class:"relative flex-1 rounded-full bg-border"})]),_:1},16,["class"]))}}),dke=ve({__name:"ScrollArea",props:{type:{},dir:{},scrollHideDelay:{},asChild:{type:Boolean},as:{},class:{}},setup(e){const t=e,n=Ie(()=>{const{class:r,...i}=t;return i});return(r,i)=>(fe(),Se(D(wie),Ue(n.value,{class:D(dt)("relative overflow-hidden",t.class)}),{default:ce(()=>[te(D(xie),{class:"h-full w-full rounded-[inherit]"},{default:ce(()=>[we(r.$slots,"default")]),_:3}),te(GY),te(D(Lie))]),_:3},16,["class"]))}}),Oke=ve({__name:"Avatar",props:{class:{},size:{default:"sm"},shape:{default:"circle"}},setup(e){const t=e;return(n,r)=>(fe(),Se(D(Hne),{class:xt(D(dt)(D(hke)({size:n.size,shape:n.shape}),t.class))},{default:ce(()=>[we(n.$slots,"default")]),_:3},8,["class"]))}}),fke=ve({__name:"AvatarFallback",props:{delayMs:{},asChild:{type:Boolean},as:{}},setup(e){const t=e;return(n,r)=>(fe(),Se(D(ere),Nt(Lt(t)),{default:ce(()=>[we(n.$slots,"default")]),_:3},16))}}),pke=ve({__name:"AvatarImage",props:{src:{},asChild:{type:Boolean},as:{}},setup(e){const t=e;return(n,r)=>(fe(),Se(D(Jne),Ue(t,{class:"h-full w-full object-cover"}),null,16))}}),hke=g0("inline-flex items-center justify-center font-normal text-foreground select-none shrink-0 bg-secondary overflow-hidden",{variants:{size:{sm:"h-10 w-10 text-xs",base:"h-16 w-16 text-2xl",lg:"h-32 w-32 text-5xl"},shape:{circle:"rounded-full",square:"rounded-md"}}}),mke={key:0,class:"p-6 pb-12 flex flex-col gap-4 items-start justify-start min-w-[1000px] relative shadow-[0px_20px_40px_0px_rgba(0,0,0,0.25)]"},gke={class:"flex flex-col gap-1.5 items-start justify-start self-stretch shrink-0 relative"},_ke={class:"flex flex-row gap-2 items-center justify-start self-stretch shrink-0 relative"},bke={class:"text-text-text-foreground text-left font-['Inter-SemiBold',_sans-serif] text-lg leading-[18px] font-semibold relative",style:{"letter-spacing":"-0.025em"}},yke={class:"flex flex-row gap-1 items-start justify-start shrink-0 relative"},vke={class:"bg-[#6D28D933] rounded-radius-rounded-xl pr-1.5 pl-1.5 flex flex-row gap-1 items-center justify-center shrink-0 min-w-[40px] relative overflow-hidden"},Ske={class:"text-text-text-foreground text-left font-['Inter-Regular',_sans-serif] text-sm leading-5 font-normal relative flex-1"},Eke={class:"bg-[#6D28D933] rounded-radius-rounded-xl pr-1.5 pl-1.5 flex flex-row gap-1 items-center justify-center shrink-0 min-w-[40px] relative overflow-hidden"},Tke={class:"text-text-text-foreground text-left font-['Inter-Regular',_sans-serif] text-sm leading-5 font-normal relative flex-1"},wke={class:"bg-[#6D28D933] rounded-radius-rounded-xl pr-1.5 pl-1.5 flex flex-row gap-1 items-center justify-center shrink-0 min-w-[40px] relative overflow-hidden"},xke={class:"text-text-text-foreground text-left font-['Inter-Regular',_sans-serif] text-sm leading-5 font-normal relative flex-1"},$ke={class:"flex flex-row gap-1 items-center justify-start self-stretch shrink-0 relative"},Pke={class:"bg-[#4e4e4e] rounded-lg p-1 flex flex-row gap-4 items-start justify-start self-stretch shrink-0 relative"},Rke={class:"min-w-[200px] max-w-[600px]"},Qke={class:"whitespace-nowrap"},kke={class:"flex gap-8"},Cke={class:"flex flex-row gap-4 items-start justify-start shrink-0 relative"},Ake={class:"text-text-text-muted-foreground text-left font-['Inter-Regular',_sans-serif] text-xs leading-5 font-normal relative"},Ike={class:"text-text-text-muted-foreground text-left font-['Inter-Regular',_sans-serif] text-xs leading-5 font-normal relative"},Dke={class:"flex flex-row gap-8 items-start justify-start self-stretch flex-1 relative"},Nke={class:"flex flex-col gap-4 items-start justify-start relative min-w-[620px] w-[65%] overflow-hidden"},Mke={class:"w-full min-h-[80vh]"},Lke={key:1,class:"w-full h-[80vh] bg-[#353535] rounded-tl-lg rounded-tr-lg"},Uke={class:"flex flex-col gap-6 items-start justify-start w-[40%] relative"},Xke={class:"pb-8 flex flex-col gap-6 items-start justify-start shrink-0 h-[97px] relative"},zke={class:"flex flex-row gap-2 items-center justify-start shrink-0 relative"},Bke={class:"flex flex-row gap-1.5 items-start justify-start self-stretch shrink-0 relative"},Fke={class:"rounded-[6px] border-solid border-[rgba(78,78,78,0.50)] border flex flex-col gap-0 items-start justify-start self-stretch shrink-0 relative text-[#F9FAFB] font-inter text-sm font-medium leading-5"},Wke={className:"flex w-full text-gray-300 text-sm"},Vke={className:"flex-1 p-4 border-b text-sm border-[rgba(78,78,78,0.50)]"},Yke={className:"flex w-full"},jke={className:"flex-1 p-4 border-b border-[rgba(78,78,78,0.50)]"},qke={className:"flex w-full"},Gke={className:"flex-1 p-4 border-b border-[rgba(78,78,78,0.50)]"},Zke={className:"flex w-full"},Hke={className:"flex-1 p-4 border-b border-[rgba(78,78,78,0.50)] flex items-center gap-2"},Kke={className:"flex w-full"},Jke={className:"flex-1 p-4 border-b border-[rgba(78,78,78,0.50)] flex flex-row gap-2"},eCe={class:"bg-[#6D28D933] rounded-radius-rounded-xl pr-1.5 pl-1.5 flex flex-row gap-1 items-center justify-center shrink-0 min-w-[40px] relative overflow-hidden"},tCe={class:"text-text-text-foreground text-left font-['Inter-Regular',_sans-serif] text-sm leading-5 font-normal relative flex-1"},nCe={class:"bg-[#6D28D933] rounded-radius-rounded-xl pr-1.5 pl-1.5 flex flex-row gap-1 items-center justify-center shrink-0 min-w-[40px] relative overflow-hidden"},rCe={class:"text-text-text-foreground text-left font-['Inter-Regular',_sans-serif] text-sm leading-5 font-normal relative flex-1"},iCe={class:"bg-[#6D28D933] rounded-radius-rounded-xl pr-1.5 pl-1.5 flex flex-row gap-1 items-center justify-center shrink-0 min-w-[40px] relative overflow-hidden"},aCe={class:"text-text-text-foreground text-left font-['Inter-Regular',_sans-serif] text-sm leading-5 font-normal relative flex-1"},oCe={class:"rounded-md border-solid border-[#4e4e4e] border flex flex-col gap-0 items-start justify-start self-stretch shrink-0 relative"},sCe={class:"flex px-[8px] py-4 items-center self-stretch text-[#F9FAFB] font-inter text-xs font-medium leading-5"},lCe=dp(ve({__name:"Index",props:{modelId:{},version:{}},setup(e){const t=su(),n=xe(),r=xe(),i=xe(!1),a=xe(null),o=e,s=async()=>{const b=await y2({id:o.modelId,source:t.mode});if(!b.data){Ut.error("Model not found."),t.closeAndReload();return}n.value=b.data,l()},l=()=>{var b;if(n.value&&n.value.versions&&n.value.versions.length>0)if((b=o.version)!=null&&b.id){const y=n.value.versions.find(v=>v.id===o.version.id);y&&(r.value={...y},bt(()=>{var v;p((v=o.version)==null?void 0:v.id)}))}else r.value={...n.value.versions[0]},bt(()=>{var y;(y=r.value)!=null&&y.id&&p(r.value.id)})};ht(async()=>{await s()});const c=b=>{var v,E;const y=(E=(v=n.value)==null?void 0:v.versions)==null?void 0:E.find(w=>w.id===b);y&&(r.value=y)},u=()=>{i.value=!i.value},d=async()=>{var b;await sce((b=r.value)==null?void 0:b.id),s()},O=async()=>{var b;await lce((b=r.value)==null?void 0:b.id),await s()},f=b=>{bt(()=>{setTimeout(()=>{if(!a.value)return;const y=a.value.$el.querySelector("[data-radix-scroll-area-viewport]"),v=y==null?void 0:y.querySelector('[role="tablist"]'),E=v==null?void 0:v.querySelector(`[role="tab"].version-tab-${b}`);if(!y||!E||!v)return;const T=Array.from(v.querySelectorAll('[role="tab"]')).reduce((k,P)=>k+P.offsetWidth,0);v.style.width=`${T}px`;const S=E.offsetLeft,x=y.clientWidth,$=E.offsetWidth,Q=Math.max(0,S-(x-$)/2);y.scrollTo({left:Q,behavior:"smooth"})},100)})},p=b=>{setTimeout(()=>{f(b)},200)},h=async(b,y)=>{var v,E,w;if(b==="edit"&&(t.setModelDetail(n),t.setDialogStatus(!0,Number((v=r.value)==null?void 0:v.id)),i.value=!1),b==="remove"){if(i.value=!1,!await t_({title:"Are you sure you want to delete this model?",desc:"This action cannot be undone.",cancel:"No, Keep It",continue:"Yes, Delete It",z:"z-9000"}))return;if((E=n.value)!=null&&E.versions&&((w=n.value)==null?void 0:w.versions.some(x=>x.public))){Ut.warning("Model has public version, cannot remove.");return}m(y)}},m=async b=>{try{await v2(b),Ut.success("Model removed successfully."),t.reload+=1}catch(y){Ut.error("Failed to remove model."),console.error("Error removing model:",y)}},g=()=>{r.value&&n.value&&t.setApplyObject(r.value,n.value)},_=async b=>{try{if(navigator.clipboard)await navigator.clipboard.writeText(b||""),Ut.success("Copied successfully.");else{const y=document.createElement("input");y.value=b||"",document.body.appendChild(y),y.select(),document.execCommand("copy"),document.body.removeChild(y)}}catch{Ut.error("Copy failed.")}};return(b,y)=>{var v,E,w,T,S,x,$,Q,k,P,R,C,I,X,F,z,J,ne,re,Z,W,j,q,G,ie,le,ae,pe,K,A,N;return n.value?(fe(),qe("div",mke,[$e("div",gke,[$e("div",_ke,[$e("div",bke,Ot(D(pE)((v=n.value)==null?void 0:v.name,60)),1),$e("div",yke,[$e("div",vke,[y[3]||(y[3]=$e("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 16 16",fill:"none"},[$e("path",{d:"M3.33325 2L12.6666 8L3.33325 14V2Z",stroke:"#F9FAFB","stroke-linecap":"round","stroke-linejoin":"round"})],-1)),$e("div",Ske,Ot(D(vd)((w=(E=n.value)==null?void 0:E.counter)==null?void 0:w.used_count)),1)])]),$e("div",Eke,[y[4]||(y[4]=$e("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 16 16",fill:"none"},[$e("path",{d:"M7.99992 1.33325L10.0599 5.50659L14.6666 6.17992L11.3333 9.42659L12.1199 14.0133L7.99992 11.8466L3.87992 14.0133L4.66659 9.42659L1.33325 6.17992L5.93992 5.50659L7.99992 1.33325Z",stroke:"#F9FAFB","stroke-linecap":"round","stroke-linejoin":"round"})],-1)),$e("div",Tke,Ot(D(vd)((S=(T=n.value)==null?void 0:T.counter)==null?void 0:S.forked_count)),1)]),$e("div",wke,[y[5]||(y[5]=mg('',1)),$e("div",xke,Ot(D(vd)(($=(x=n.value)==null?void 0:x.counter)==null?void 0:$.liked_count)),1)])]),$e("div",$ke,[$e("div",Pke,[$e("div",Rke,[te(D(dke),{ref_key:"scrollViewportRef",ref:a,class:"rounded-md w-full"},{default:ce(()=>{var M,oe;return[$e("div",Qke,[te(D(YY),{defaultValue:(M=r.value)==null?void 0:M.id,value:(oe=r.value)==null?void 0:oe.id},{default:ce(()=>[te(D(jY),{class:"inline-flex h-12 bg-transparent text-sm text-white w-auto"},{default:ce(()=>{var se;return[(fe(!0),qe(Pt,null,Oi((se=n.value)==null?void 0:se.versions,V=>(fe(),Se(D(qY),{value:V.id,onClick:ee=>c(V.id),class:xt([["version-tab",`version-tab-${V.id}`],"text-sm t bg-[#9CA3AF] data-[state=active]:bg-[#7C3AED] h-10 px-3 py-2 mx-1"])},{default:ce(()=>[ot(Ot(V.version),1)]),_:2},1032,["value","onClick","class"]))),256))]}),_:1})]),_:1},8,["defaultValue","value"])]),te(D(GY),{orientation:"horizontal"})]}),_:1},512)])]),y[10]||(y[10]=$e("div",{class:"text-text-text-muted-foreground text-left font-['Inter-Regular',_sans-serif] text-xs leading-5 font-normal relative flex-1"},null,-1)),$e("div",kke,[(fe(),qe("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 16 16",fill:"none",class:"cursor-pointer",onClick:d,style:Ei({stroke:(Q=r.value)!=null&&Q.liked?"#6D28D9":"#F9FAFB",fill:(k=r.value)!=null&&k.liked?"#6D28D9":"none"})},y[6]||(y[6]=[$e("g",{"clip-path":"url(#clip0_440_1289)"},[$e("path",{d:"M4.66659 6.66658V14.6666M9.99992 3.91992L9.33325 6.66658H13.2199C13.4269 6.66658 13.6311 6.71478 13.8162 6.80735C14.0013 6.89992 14.1624 7.03432 14.2866 7.19992C14.4108 7.36551 14.4947 7.55775 14.5317 7.7614C14.5688 7.96506 14.5579 8.17454 14.4999 8.37325L12.9466 13.7066C12.8658 13.9835 12.6974 14.2268 12.4666 14.3999C12.2358 14.573 11.9551 14.6666 11.6666 14.6666H2.66659C2.31296 14.6666 1.97382 14.5261 1.72378 14.2761C1.47373 14.026 1.33325 13.6869 1.33325 13.3333V7.99992C1.33325 7.6463 1.47373 7.30716 1.72378 7.05711C1.97382 6.80706 2.31296 6.66658 2.66659 6.66658H4.50659C4.75464 6.66645 4.99774 6.59713 5.20856 6.4664C5.41937 6.33567 5.58953 6.14873 5.69992 5.92659L7.99992 1.33325C8.3143 1.33715 8.62374 1.41203 8.90512 1.55232C9.1865 1.6926 9.43254 1.89466 9.62486 2.14339C9.81717 2.39212 9.9508 2.68109 10.0157 2.98872C10.0807 3.29635 10.0753 3.61468 9.99992 3.91992Z","stroke-linecap":"round","stroke-linejoin":"round"})],-1),$e("defs",null,[$e("clipPath",{id:"clip0_440_1289"},[$e("rect",{width:"16",height:"16",fill:"white"})])],-1)]),4)),D(t).mode==="my"||D(t).mode==="my_fork"?(fe(),Se(D(xy),{key:0,class:"bg-[#353535]",open:i.value,"onUpdate:open":u},{default:ce(()=>[te(D(Py),{class:"bg-transparent"},{default:ce(()=>y[7]||(y[7]=[$e("div",{class:"flex justify-center items-center rounded-md w-8 relative z-50"},[$e("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 16 16",fill:"none",class:"cursor-pointer"},[$e("path",{d:"M8.66659 7.99992C8.66659 7.63173 8.36811 7.33325 7.99992 7.33325C7.63173 7.33325 7.33325 7.63173 7.33325 7.99992C7.33325 8.36811 7.63173 8.66659 7.99992 8.66659C8.36811 8.66659 8.66659 8.36811 8.66659 7.99992Z",stroke:"#F9FAFB","stroke-linecap":"round","stroke-linejoin":"round"}),$e("path",{d:"M8.66659 3.33325C8.66659 2.96506 8.36811 2.66658 7.99992 2.66658C7.63173 2.66658 7.33325 2.96506 7.33325 3.33325C7.33325 3.70144 7.63173 3.99992 7.99992 3.99992C8.36811 3.99992 8.66659 3.70144 8.66659 3.33325Z",stroke:"#F9FAFB","stroke-linecap":"round","stroke-linejoin":"round"}),$e("path",{d:"M8.66659 12.6666C8.66659 12.2984 8.36811 11.9999 7.99992 11.9999C7.63173 11.9999 7.33325 12.2984 7.33325 12.6666C7.33325 13.0348 7.63173 13.3333 7.99992 13.3333C8.36811 13.3333 8.66659 13.0348 8.66659 12.6666Z",stroke:"#F9FAFB","stroke-linecap":"round","stroke-linejoin":"round"})])],-1)])),_:1}),te(D($y),{side:"bottom",align:"end",class:"w-[150px] p-0 bg-[#353535] rounded-lg group-hover:visible z-15000"},{default:ce(()=>[te(D(Ry),null,{default:ce(()=>[te(D(Qy),null,{default:ce(()=>[te(D(Uh),null,{default:ce(()=>[te(D(cl),{value:"edit",onClick:y[0]||(y[0]=M=>{var oe;return h("edit",(oe=n.value)==null?void 0:oe.id)}),class:"px-2 py-1.5 mb-1 text-[#F9FAFB] cursor-pointer [&:hover]:!bg-[#6D28D9] [&:hover]:!text-[#F9FAFB]"},{default:ce(()=>y[8]||(y[8]=[ot(" Edit ")])),_:1}),te(D(uQ)),te(D(cl),{value:"remove",onClick:y[1]||(y[1]=M=>{var oe;return h("remove",(oe=n.value)==null?void 0:oe.id)}),class:"px-2 py-1.5 mb-1 mt-1 text-[#F9FAFB] cursor-pointer [&:hover]:!bg-[#6D28D9] [&:hover]:!text-[#F9FAFB]"},{default:ce(()=>y[9]||(y[9]=[ot(" Remove ")])),_:1})]),_:1})]),_:1})]),_:1})]),_:1})]),_:1},8,["open"])):kt("",!0)])]),$e("div",Cke,[$e("div",Ake," First Published: "+Ot((P=r.value)==null?void 0:P.created_at),1),$e("div",Ike," Last Updated: "+Ot((R=r.value)==null?void 0:R.updated_at),1)])]),$e("div",Dke,[$e("div",Nke,[$e("div",Mke,[(C=r.value)!=null&&C.intro?(fe(),Se(D(Lp),{key:0,id:"previewRef",modelValue:(I=r.value)==null?void 0:I.intro,noImgZoomIn:!0,preview:!0,theme:"dark",class:"bg-[#353535] w-full min-h-[80vh]"},null,8,["modelValue"])):(fe(),qe("div",Lke,y[11]||(y[11]=[$e("div",{class:"flex justify-center items-center h-full"},[$e("div",{class:"text-text-text-muted-foreground text-left font-['Inter-Regular',_sans-serif] text-xs leading-5 font-normal relative"}," No introduction yet ")],-1)])))])]),$e("div",Uke,[$e("div",Xke,[$e("div",zke,[te(D(Oke),null,{default:ce(()=>[te(D(pke),{src:"https://github.com/radix-vue.png",alt:"@radix-vue"}),te(D(fke),null,{default:ce(()=>{var M,oe;return[ot(Ot((oe=(M=n.value)==null?void 0:M.user_name)==null?void 0:oe.slice(0,2)),1)]}),_:1})]),_:1}),ot(" "+Ot((X=n.value)==null?void 0:X.user_name),1)]),$e("div",Bke,[D(t).mode==="publicity"?(fe(),Se(D(Ur),{key:0,variant:"default",class:"w-[124px] flex h-9 px-3 py-2 justify-center items-center gap-2 flex-1 rounded-md bg-[#6D28D9]",onClick:O,disabled:(F=r.value)==null?void 0:F.forked},{default:ce(()=>{var M;return[ot(Ot((M=r.value)!=null&&M.forked?"Forked":"Fork"),1)]}),_:1},8,["disabled"])):kt("",!0),te(D(Ur),{onClick:g,class:"flex w-[170px] px-8 py-2 justify-center items-center gap-2 bg-[#F43F5E] hover:bg-[#F43F5E]/90 rounded-[6px]"},{default:ce(()=>y[12]||(y[12]=[$e("svg",{xmlns:"http://www.w3.org/2000/svg",width:"17",height:"16",viewBox:"0 0 17 16",fill:"none"},[$e("path",{d:"M6.49988 7.9999L7.83322 9.33324L10.4999 6.66657M3.06655 5.74657C2.96925 5.30825 2.98419 4.85246 3.10999 4.42146C3.23579 3.99046 3.46838 3.5982 3.7862 3.28105C4.10401 2.9639 4.49676 2.73213 4.92802 2.60723C5.35929 2.48233 5.81511 2.46835 6.25322 2.56657C6.49436 2.18944 6.82655 1.87907 7.21919 1.66409C7.61182 1.44911 8.05225 1.33643 8.49988 1.33643C8.94752 1.33643 9.38795 1.44911 9.78058 1.66409C10.1732 1.87907 10.5054 2.18944 10.7466 2.56657C11.1853 2.46792 11.6419 2.48184 12.0739 2.60704C12.5058 2.73225 12.8991 2.96466 13.2171 3.28267C13.5351 3.60068 13.7675 3.99395 13.8927 4.4259C14.0179 4.85786 14.0319 5.31446 13.9332 5.75324C14.3104 5.99437 14.6207 6.32657 14.8357 6.7192C15.0507 7.11183 15.1634 7.55227 15.1634 7.9999C15.1634 8.44754 15.0507 8.88797 14.8357 9.2806C14.6207 9.67323 14.3104 10.0054 13.9332 10.2466C14.0314 10.6847 14.0175 11.1405 13.8926 11.5718C13.7677 12.003 13.5359 12.3958 13.2187 12.7136C12.9016 13.0314 12.5093 13.264 12.0783 13.3898C11.6473 13.5156 11.1915 13.5305 10.7532 13.4332C10.5124 13.8118 10.1799 14.1235 9.78663 14.3394C9.39333 14.5554 8.9519 14.6686 8.50322 14.6686C8.05453 14.6686 7.6131 14.5554 7.2198 14.3394C6.8265 14.1235 6.49404 13.8118 6.25322 13.4332C5.81511 13.5315 5.35929 13.5175 4.92802 13.3926C4.49676 13.2677 4.10401 13.0359 3.7862 12.7188C3.46838 12.4016 3.23579 12.0093 3.10999 11.5783C2.98419 11.1473 2.96925 10.6916 3.06655 10.2532C2.68652 10.0127 2.37349 9.68002 2.15658 9.28605C1.93967 8.89207 1.82593 8.44964 1.82593 7.9999C1.82593 7.55016 1.93967 7.10773 2.15658 6.71376C2.37349 6.31979 2.68652 5.98707 3.06655 5.74657Z",stroke:"#F9FAFB","stroke-linecap":"round","stroke-linejoin":"round"})],-1),ot("Apply")])),_:1})])]),$e("div",Fke,[$e("div",Wke,[y[13]||(y[13]=$e("div",{className:"w-[100px] bg-[#4E4E4E80] p-4 border-b border-[rgba(78,78,78,0.50)]"}," Type",-1)),$e("div",Vke,[$e("span",{class:xt(`${(z=n.value)==null?void 0:z.type} inline-flex px-[10px] py-[2px] items-start gap-[10px] rounded-[9999px] relative overflow-hidden`)},Ot((J=n.value)==null?void 0:J.type),3)])]),$e("div",Yke,[y[14]||(y[14]=$e("div",{className:"w-[100px] bg-[#4E4E4E80] p-4 text-sm border-b border-[rgba(78,78,78,0.50)] whitespace-nowrap"}," Base Model",-1)),$e("div",jke,Ot((ne=r.value)==null?void 0:ne.base_model),1)]),$e("div",qke,[y[15]||(y[15]=$e("div",{className:"w-[100px] bg-[#4E4E4E80] p-4 border-b border-[rgba(78,78,78,0.50)]"}," Published",-1)),$e("div",Gke,Ot((re=r.value)==null?void 0:re.created_at),1)]),$e("div",Zke,[y[17]||(y[17]=$e("div",{className:"w-[100px] bg-[#4E4E4E80] p-4 border-b border-[rgba(78,78,78,0.50)]"}," Hash",-1)),$e("div",Hke,[$e("span",null,Ot((Z=r.value)!=null&&Z.sign?D(pE)((W=r.value)==null?void 0:W.sign,15):""),1),(j=r.value)!=null&&j.sign?(fe(),qe("svg",{key:0,xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 16 16",fill:"none",class:"cursor-pointer hover:opacity-80",onClick:y[2]||(y[2]=M=>{var oe;return _(((oe=r.value)==null?void 0:oe.sign)||"")})},y[16]||(y[16]=[$e("g",{"clip-path":"url(#clip0_315_3710)"},[$e("path",{d:"M2.66659 10.6666C1.93325 10.6666 1.33325 10.0666 1.33325 9.33325V2.66659C1.33325 1.93325 1.93325 1.33325 2.66659 1.33325H9.33325C10.0666 1.33325 10.6666 1.93325 10.6666 2.66659M6.66658 5.33325H13.3333C14.0696 5.33325 14.6666 5.93021 14.6666 6.66658V13.3333C14.6666 14.0696 14.0696 14.6666 13.3333 14.6666H6.66658C5.93021 14.6666 5.33325 14.0696 5.33325 13.3333V6.66658C5.33325 5.93021 5.93021 5.33325 6.66658 5.33325Z",stroke:"#9CA3AF","stroke-linecap":"round","stroke-linejoin":"round"})],-1),$e("defs",null,[$e("clipPath",{id:"clip0_315_3710"},[$e("rect",{width:"16",height:"16",fill:"white"})])],-1)]))):kt("",!0)])]),$e("div",Kke,[y[21]||(y[21]=$e("div",{className:"w-[100px] bg-[#4E4E4E80] p-4 text-gray-300 border-b border-[rgba(78,78,78,0.50)]"}," Stats",-1)),$e("div",Jke,[$e("div",eCe,[y[18]||(y[18]=$e("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 16 16",fill:"none"},[$e("path",{d:"M3.33325 2L12.6666 8L3.33325 14V2Z",stroke:"#F9FAFB","stroke-linecap":"round","stroke-linejoin":"round"})],-1)),$e("div",tCe,Ot(D(vd)((G=(q=r.value)==null?void 0:q.counter)==null?void 0:G.used_count)),1)]),$e("div",nCe,[y[19]||(y[19]=$e("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 16 16",fill:"none"},[$e("path",{d:"M7.99992 1.33325L10.0599 5.50659L14.6666 6.17992L11.3333 9.42659L12.1199 14.0133L7.99992 11.8466L3.87992 14.0133L4.66659 9.42659L1.33325 6.17992L5.93992 5.50659L7.99992 1.33325Z",stroke:"#F9FAFB","stroke-linecap":"round","stroke-linejoin":"round"})],-1)),$e("div",rCe,Ot(D(vd)((le=(ie=r.value)==null?void 0:ie.counter)==null?void 0:le.forked_count)),1)]),$e("div",iCe,[y[20]||(y[20]=mg('',1)),$e("div",aCe,Ot(D(vd)((pe=(ae=r.value)==null?void 0:ae.counter)==null?void 0:pe.liked_count)),1)])])])]),$e("div",oCe,[y[22]||(y[22]=$e("div",{class:"bg-[#424242] rounded-md flex items-center justify-start self-stretch shrink-0 relative h-[44px] pl-2"}," File ",-1)),$e("div",sCe,Ot((K=r.value)!=null&&K.file_name?D(pE)((A=r.value)==null?void 0:A.file_name,20):"")+" ("+Ot(D(Cee)((N=r.value)==null?void 0:N.file_size))+") ",1)])])])])):kt("",!0)}}}),[["__scopeId","data-v-1848d10c"]]),cCe={class:"text-sm text-white-500 flex items-center min-w-0"},uCe={class:"truncate flex-1"},dCe={class:"flex-shrink-0 ml-2"},OCe={key:0,xmlns:"http://www.w3.org/2000/svg",width:"16",height:"17",viewBox:"0 0 16 17",fill:"none"},fCe={key:1,xmlns:"http://www.w3.org/2000/svg",width:"16",height:"17",viewBox:"0 0 16 17",fill:"none"},pCe=ve({__name:"ModelVersionRow",props:{version:{},model:{}},setup(e){const t=su(),n=xe(!1);Be(()=>t.reload,(a,o)=>{a!==o&&(n.value=!1)},{deep:!0});const r=(a,o)=>{t.setApplyObject(a,o)},i=()=>{n.value=!0};return(a,o)=>(fe(),qe(Pt,null,[te(D(Xh),{class:"bg-[#3D3D3D] hover:bg-[#4E4E4E] hover:cursor-pointer border-[#F9FAFB]/60 h-12",onClick:i},{default:ce(()=>[te(D(Os),{class:"pl-10 w-[55%] max-w-[200px]"},{default:ce(()=>[$e("div",cCe,[$e("span",uCe,Ot(a.version.version),1),$e("div",dCe,[a.version.public?(fe(),qe("svg",OCe,o[2]||(o[2]=[$e("path",{d:"M1.33325 8.49992C1.33325 8.49992 3.33325 3.83325 7.99992 3.83325C12.6666 3.83325 14.6666 8.49992 14.6666 8.49992C14.6666 8.49992 12.6666 13.1666 7.99992 13.1666C3.33325 13.1666 1.33325 8.49992 1.33325 8.49992Z",stroke:"#9CA3AF","stroke-linecap":"round","stroke-linejoin":"round"},null,-1),$e("path",{d:"M7.99992 10.4999C9.10449 10.4999 9.99992 9.60449 9.99992 8.49992C9.99992 7.39535 9.10449 6.49992 7.99992 6.49992C6.89535 6.49992 5.99992 7.39535 5.99992 8.49992C5.99992 9.60449 6.89535 10.4999 7.99992 10.4999Z",stroke:"#9CA3AF","stroke-linecap":"round","stroke-linejoin":"round"},null,-1)]))):(fe(),qe("svg",fCe,o[3]||(o[3]=[$e("path",{d:"M6.58658 7.08659C6.39009 7.26968 6.23248 7.49048 6.12317 7.73582C6.01386 7.98115 5.95508 8.24598 5.95034 8.51452C5.9456 8.78307 5.995 9.04981 6.09559 9.29884C6.19618 9.54788 6.3459 9.7741 6.53582 9.96402C6.72573 10.1539 6.95196 10.3037 7.20099 10.4042C7.45003 10.5048 7.71677 10.5542 7.98531 10.5495C8.25385 10.5448 8.51869 10.486 8.76402 10.3767C9.00935 10.2674 9.23015 10.1097 9.41325 9.91325M7.15325 3.88659C7.43412 3.85159 7.71687 3.83378 7.99992 3.83325C12.6666 3.83325 14.6666 8.49992 14.6666 8.49992C14.3685 9.138 13.9947 9.73787 13.5533 10.2866M4.40659 4.90659C3.08075 5.80967 2.01983 7.05009 1.33325 8.49992C1.33325 8.49992 3.33325 13.1666 7.99992 13.1666C9.27719 13.17 10.5271 12.7967 11.5933 12.0933M1.33325 1.83325L14.6666 15.1666",stroke:"#9CA3AF","stroke-linecap":"round","stroke-linejoin":"round"},null,-1)])))])])]),_:1}),te(D(Os),{class:"w-[15%]"},{default:ce(()=>[ot(Ot(a.version.base_model),1)]),_:1}),te(D(Os),{class:"w-[15%]"},{default:ce(()=>[ot(Ot(a.version.available?"Available":"Unavailable"),1)]),_:1}),te(D(Os),{class:"w-[15%] flex justify-start"},{default:ce(()=>[te(D(Ur),{variant:"default",onClick:o[0]||(o[0]=Sr(s=>r(a.version,a.model),["stop"])),disabled:!a.version.available,class:xt({"opacity-50":!a.version.available})},{default:ce(()=>o[4]||(o[4]=[ot(" Apply ")])),_:1},8,["disabled","class"])]),_:1})]),_:1}),te(n_,{open:n.value,"onUpdate:open":o[1]||(o[1]=s=>n.value=s),class:"max-w-full h-screen px-6 overflow-hidden pb-6 z-8000",layoutClass:"z-8000",contentClass:"custom-scrollbar max-h-[100vh-120px] overflow-y-auto w-full rounded-tl-lg rounded-tr-lg custom-shadow",title:a.model.name},{default:ce(()=>[te(D(lCe),{modelId:a.model.id,version:a.version},null,8,["modelId","version"])]),_:1},8,["open","title"])],64))}}),hCe={class:"flex items-center justify-center h-full"},mCe={class:"flex items-center space-x-2"},gCe={class:"text-sm"},_Ce={key:0,xmlns:"http://www.w3.org/2000/svg",width:"16",height:"17",viewBox:"0 0 16 17",fill:"none"},bCe={key:1,xmlns:"http://www.w3.org/2000/svg",width:"16",height:"17",viewBox:"0 0 16 17",fill:"none"},yCe={class:"flex justify-end h-full"},vCe={key:1,class:"w-8 h-8"},SCe={class:"w-full flex justify-center mt-8"},ECe=ve({__name:"ModelTable",setup(e){const t=su(),n=xe(new Set),r=xe(""),i=Ie(()=>t.isLoading);Be(()=>t.models,l=>{l.length>0&&(n.value.clear(),n.value.add(l[0].name))},{deep:!0});const a=l=>{n.value.has(l)?n.value.delete(l):n.value.add(l)},o=async(l,c)=>{const{id:u,name:d,versions:O}=c;if(r.value=d,l==="edit"){const f=await y2({id:c.id,source:t.mode});t.setModelDetail(f.data),t.setDialogStatus(!0),r.value=""}if(l==="remove"){if(t.reloadModelSelectList=!1,!await t_({title:"Are you sure you want to delete this model?",desc:"This action cannot be undone.",cancel:"No, Keep It",continue:"Yes, Delete It",z:"z-9000"}))return;if(O&&O.some(h=>h.public)){Ut.warning("Model has public version, cannot remove.");return}s(u)}},s=async l=>{try{await v2(l),Ut.success("Model removed successfully."),t.reloadModelSelectList=!0}catch(c){Ut.error(`Failed to remove model. ${c}`)}};return(l,c)=>(fe(),qe("div",null,[te(D(lke),null,{default:ce(()=>[te(D(uke),null,{default:ce(()=>[te(D(Xh),{class:"hover:bg-transparent border-[#F9FAFB]/60"},{default:ce(()=>[te(D(ky),{class:"w-[55%]"},{default:ce(()=>c[0]||(c[0]=[ot("Name")])),_:1}),te(D(ky),{class:"w-[15%]"},{default:ce(()=>c[1]||(c[1]=[ot("Base Model")])),_:1}),te(D(ky),{class:"w-[15%]"},{default:ce(()=>c[2]||(c[2]=[ot("Status")])),_:1}),te(D(ky),{class:"w-[15%]"},{default:ce(()=>c[3]||(c[3]=[ot("Operate")])),_:1})]),_:1})]),_:1}),te(D(cke),null,{default:ce(()=>[i.value?(fe(),Se(D(Xh),{key:0,class:"bg-transparent hover:bg-transparent"},{default:ce(()=>[te(D(Os),{colspan:"4",class:"h-[400px]"},{default:ce(()=>[$e("div",hCe,[te(D(voe),{class:"h-8 w-8 animate-spin text-[#F9FAFB]"})])]),_:1})]),_:1})):(fe(),qe(Pt,{key:1},[!i.value&&D(t).models.length>0?(fe(!0),qe(Pt,{key:0},Oi(D(t).models,u=>(fe(),qe(Pt,{key:`${u.id}-${u.name}`},[te(D(Xh),{class:"group cursor-pointer border-[#F9FAFB]/60 hover:bg-transparent h-12"},{default:ce(()=>[te(D(Os),{class:"w-[55%]",onClick:d=>a(u.name)},{default:ce(()=>[$e("div",mCe,[$e("span",gCe,[n.value.has(u.name)?(fe(),qe("svg",_Ce,c[4]||(c[4]=[$e("path",{d:"M4 6L8 10L12 6",stroke:"#F9FAFB","stroke-width":"1.5","stroke-linecap":"round","stroke-linejoin":"round"},null,-1)]))):(fe(),qe("svg",bCe,c[5]||(c[5]=[$e("path",{d:"M6 4L10 8L6 12",stroke:"#F9FAFB","stroke-width":"1.5","stroke-linecap":"round","stroke-linejoin":"round"},null,-1)])))]),$e("span",null,Ot(u.name),1),te(D(cQ),{variant:"default"},{default:ce(()=>[ot(Ot(u.type),1)]),_:2},1024)])]),_:2},1032,["onClick"]),te(D(Os),{class:"w-[15%]"},{default:ce(()=>c[6]||(c[6]=[ot("-")])),_:1}),te(D(Os),{class:"w-[15%]"},{default:ce(()=>c[7]||(c[7]=[ot("-")])),_:1}),te(D(Os),{class:"w-[15%]"},{default:ce(()=>[$e("div",yCe,[D(t).mode==="my"||D(t).mode==="my_fork"?(fe(),Se(D(xy),{key:0,class:"bg-[#353535] z-[5100]mmm",open:r.value===u.name,"onUpdate:open":d=>d?r.value=u.name:r.value=""},{default:ce(()=>[te(D(Py),{class:"bg-transparent"},{default:ce(()=>c[8]||(c[8]=[$e("div",{class:"flex justify-center items-center hover:bg-[#222222] rounded-md w-8 h-8"},[$e("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24"},[$e("path",{fill:"white",d:"M12 16a2 2 0 0 1 2 2a2 2 0 0 1-2 2a2 2 0 0 1-2-2a2 2 0 0 1 2-2m0-6a2 2 0 0 1 2 2a2 2 0 0 1-2 2a2 2 0 0 1-2-2a2 2 0 0 1 2-2m0-6a2 2 0 0 1 2 2a2 2 0 0 1-2 2a2 2 0 0 1-2-2a2 2 0 0 1 2-2"})])],-1)])),_:1}),te(D($y),{side:"bottom",align:"end",class:"w-[150px] p-0 bg-[#353535] rounded-lg group-hover:visible z-12000"},{default:ce(()=>[te(D(Ry),null,{default:ce(()=>[te(D(Qy),null,{default:ce(()=>[te(D(Uh),null,{default:ce(()=>[te(D(cl),{value:"edit",onClick:d=>o("edit",u),class:"px-2 py-1.5 mb-1 text-[#F9FAFB] cursor-pointer [&:hover]:!bg-[#6D28D9] [&:hover]:!text-[#F9FAFB]"},{default:ce(()=>c[9]||(c[9]=[ot(" Edit ")])),_:2},1032,["onClick"]),te(D(uQ)),te(D(cl),{value:"remove",onClick:d=>o("remove",u),class:"px-2 py-1.5 mb-1 mt-1 text-[#F9FAFB] cursor-pointer [&:hover]:!bg-[#6D28D9] [&:hover]:!text-[#F9FAFB]"},{default:ce(()=>c[10]||(c[10]=[ot(" Remove ")])),_:2},1032,["onClick"])]),_:2},1024)]),_:2},1024)]),_:2},1024)]),_:2},1024)]),_:2},1032,["open","onUpdate:open"])):(fe(),qe("div",vCe))])]),_:2},1024)]),_:2},1024),n.value.has(u.name)&&u.versions?(fe(!0),qe(Pt,{key:0},Oi(u.versions,d=>(fe(),Se(pCe,{model:u,key:d.version,version:d},null,8,["model","version"]))),128)):kt("",!0)],64))),128)):(fe(),Se(D(Xh),{key:1,class:"hover:bg-transparent"},{default:ce(()=>[te(D(Os),{colspan:"4",class:"h-[400px]"},{default:ce(()=>c[11]||(c[11]=[$e("div",{class:"flex items-center justify-center h-full text-[#F9FAFB]"}," No available data ",-1)])),_:1})]),_:1}))],64))]),_:1})]),_:1}),$e("div",SCe,[i.value?kt("",!0):(fe(),Se(oke,{key:0}))])]))}}),TCe={class:"font-['Inter'] flex flex-col"},wCe={class:"flex flex-col min-h-[650px]"},xCe={class:"flex-1 relative"},$Ce={class:"h-full"},PCe=ve({__name:"Index",props:{modelType:{},selectedBaseModels:{}},emits:["apply"],setup(e,{emit:t}){const n=su(),r=e,i=["my","my_fork","publicity"],a={my:"My Models",my_fork:"My Forks",publicity:"Community Models"},o=async()=>{n.setIsLoading(!0),await ice(n.modelListPathParams,n.filterState).then(p=>{var h,m;p&&p.data?(n.modelListPathParams.total=((h=p==null?void 0:p.data)==null?void 0:h.total)||0,n.models=((m=p==null?void 0:p.data)==null?void 0:m.list)||[]):(n.modelListPathParams.total=0,n.models=[])}).catch(p=>{Ut.error(`Failed to fetch model list. ${p}`),n.modelListPathParams.total=0,n.models=[]}).finally(async()=>{n.setIsLoading(!1)})},s=xe(!1),l=xe(!1),c=async p=>{n.models=[],n.mode=String(p),n.modelListPathParams.mode=n.mode,n.modelListPathParams.current=1,n.mode!=="publicity"&&(n.filterState.sort="Recently"),await o()},u=()=>b2().then(p=>(n.setModelTypes(p!=null&&p.data?p.data:[]),_2())).then(p=>{n.setBaseModelTypes(p!=null&&p.data?p.data:[])}).catch(p=>{Ut.error(`Failed to fetch base model types${p}`),n.setModelTypes([]),n.setBaseModelTypes([])}),d=t;Be(()=>n.applyObject,p=>{p.version&&p.model&&d("apply",p.version,p.model.name)},{deep:!0,immediate:!0}),Be(()=>n.closeModelSelectDialog,(p,h)=>{p!==h&&(l.value=!1)},{deep:!0}),Be(()=>n.reload,async(p,h)=>{p!==h&&await o()},{deep:!0}),Be(()=>n.reloadModelSelectList,async(p,h)=>{p!==h&&await o()},{deep:!0}),Be(()=>n.modelListPathParams.current,async(p,h)=>{p!==h&&l.value&&await o()}),ht(async()=>{r.modelType&&(n.selectedModelTypes=r.modelType,n.filterState.model_types=r.modelType),r.selectedBaseModels&&(n.selectedBaseModels=r.selectedBaseModels,n.filterState.base_models=r.selectedBaseModels),await u(),l.value=!0}),Be(()=>l.value,async p=>{p?(r.modelType&&(n.selectedModelTypes=r.modelType,n.filterState.model_types=r.modelType),r.selectedBaseModels&&(n.selectedBaseModels=r.selectedBaseModels,n.filterState.base_models=r.selectedBaseModels),await o()):n.resetModelListPathParams()});const O=async()=>{await o()},f=()=>{l.value=!1};return(p,h)=>(fe(),Se(n_,{open:l.value,"onUpdate:open":h[1]||(h[1]=m=>l.value=m),class:"max-w-[70%] px-6 pb-6 overflow-hidden z-8000",layoutClass:"z-8000",onOnClose:f,contentClass:"custom-scrollbar max-h-[78vh] overflow-y-auto w-full rounded-tl-lg rounded-tr-lg custom-shadow"},{title:ce(()=>h[2]||(h[2]=[$e("span",{class:"text-[#F9FAFB] mb-4 text-[18px] font-semibold leading-[18px] tracking-[-0.45px]"}," Select Model ",-1)])),default:ce(()=>[$e("div",TCe,[te(D(YY),{defaultValue:D(n).mode,class:"h-full flex flex-col","onUpdate:modelValue":c},{default:ce(()=>[te(D(jY),{class:"grid w-full grid-cols-3 h-12 bg-[#4E4E4E] text-white text-sm shrink-0"},{default:ce(()=>[(fe(),qe(Pt,null,Oi(i,m=>te(D(qY),{key:m,value:m,class:"text-sm data-[state=active]:bg-[#9CA3AF] bg-[#4E4E4E] h-10 px-3 py-2 focus:outline-none focus-visible:outline-none"},{default:ce(()=>[ot(Ot(a[m]),1)]),_:2},1032,["value"])),64))]),_:1}),(fe(),qe(Pt,null,Oi(i,m=>(fe(),qe(Pt,{key:m},[D(n).mode===m?(fe(),Se(D(VQe),{key:0,value:m,class:"flex-1 flex flex-col overflow-hidden"},{default:ce(()=>[$e("div",wCe,[$e("div",xCe,[te(JQe,{"show-sort-popover":s.value,"onUpdate:showSortPopover":h[0]||(h[0]=g=>s.value=g),onFetchData:O,class:"shrink-0"},null,8,["show-sort-popover"]),$e("div",$Ce,[te(ECe)])]),h[3]||(h[3]=$e("div",{class:"h-4"},null,-1))])]),_:2},1032,["value"])):kt("",!0)],64))),64))]),_:1},8,["defaultValue"])])]),_:1},8,["open"]))}}),RCe=e=>{let t=!1;const n=document.getElementById("bizyair-model-select");n&&document.body.removeChild(n);const r=document.createElement("div");r.id="bizyair-model-select",document.body.appendChild(r);const i=jf(PCe,{...e,onClose:()=>{t&&(i.unmount(),t=!1),document.body.contains(r)&&document.body.removeChild(r)},onApply:(...o)=>{e!=null&&e.onApply&&(e.onApply(...o),t&&(i.unmount(),t=!1),document.body.contains(r)&&document.body.removeChild(r))}});i.directive("debounce",{mounted(o,s){let l=null;o.addEventListener("keyup",()=>{l&&clearTimeout(l),l=setTimeout(()=>{s.value()},s.arg||500)})},unmounted(o,s){s&&o.removeEventListener("keyup",s.value)}});const a=i.mount(r);return t=!0,{instance:a}};let zh=jf(WQe);zh.use(lse());function QCe(e,t){zh.provide("comfyUIApp",t),zh.mount(e)}function kCe(){zh&&zh.unmount()}const CCe=36,ZY=1,ACe=2,WO=3,dQ=4,ICe=5,DCe=6,NCe=7,MCe=8,LCe=9,UCe=10,XCe=11,zCe=12,BCe=13,FCe=14,WCe=15,VCe=16,YCe=17,HY=18,jCe=19,KY=20,JY=21,ej=22,qCe=23,GCe=24;function OQ(e){return e>=65&&e<=90||e>=97&&e<=122||e>=48&&e<=57}function ZCe(e){return e>=48&&e<=57||e>=97&&e<=102||e>=65&&e<=70}function Mu(e,t,n){for(let r=!1;;){if(e.next<0)return;if(e.next==t&&!r){e.advance();return}r=n&&!r&&e.next==92,e.advance()}}function HCe(e,t){e:for(;;){if(e.next<0)return;if(e.next==36){e.advance();for(let n=0;n)".charCodeAt(n);for(;;){if(e.next<0)return;if(e.next==r&&e.peek(1)==39){e.advance(2);return}e.advance()}}function fQ(e,t){for(;!(e.next!=95&&!OQ(e.next));)t!=null&&(t+=String.fromCharCode(e.next)),e.advance();return t}function JCe(e){if(e.next==39||e.next==34||e.next==96){let t=e.next;e.advance(),Mu(e,t,!1)}else fQ(e)}function tj(e,t){for(;e.next==48||e.next==49;)e.advance();t&&e.next==t&&e.advance()}function nj(e,t){for(;;){if(e.next==46){if(t)break;t=!0}else if(e.next<48||e.next>57)break;e.advance()}if(e.next==69||e.next==101)for(e.advance(),(e.next==43||e.next==45)&&e.advance();e.next>=48&&e.next<=57;)e.advance()}function rj(e){for(;!(e.next<0||e.next==10);)e.advance()}function Lu(e,t){for(let n=0;n/g,GRe=/"/g,ZRe=/"/g,HRe=/&#([a-zA-Z0-9]*);?/gim,KRe=/:?/gim,JRe=/&newline;?/gim,Sy=/((j\s*a\s*v\s*a|v\s*b|l\s*i\s*v\s*e)\s*s\s*c\s*r\s*i\s*p\s*t\s*|m\s*o\s*c\s*h\s*a):/gi,IY=/e\s*x\s*p\s*r\s*e\s*s\s*s\s*i\s*o\s*n\s*\(.*/gi,DY=/u\s*r\s*l\s*\(.*/gi;function NY(e){return e.replace(GRe,""")}function MY(e){return e.replace(ZRe,'"')}function LY(e){return e.replace(HRe,function(n,r){return r[0]==="x"||r[0]==="X"?String.fromCharCode(parseInt(r.substr(1),16)):String.fromCharCode(parseInt(r,10))})}function UY(e){return e.replace(KRe,":").replace(JRe," ")}function XY(e){for(var t="",n=0,r=e.length;n",r);if(i===-1)break;n=i+3}return t}function rQe(e){var t=e.split("");return t=t.filter(function(n){var r=n.charCodeAt(0);return r===127?!1:r<=31?r===10||r===13:!0}),t.join("")}Mn.whiteList=kY(),Mn.getDefaultWhiteList=kY,Mn.onTag=BRe,Mn.onIgnoreTag=FRe,Mn.onTagAttr=WRe,Mn.onIgnoreTagAttr=VRe,Mn.safeAttrValue=YRe,Mn.escapeHtml=AY,Mn.escapeQuote=NY,Mn.unescapeQuote=MY,Mn.escapeHtmlEntities=LY,Mn.escapeDangerHtml5Entities=UY,Mn.clearNonPrintableCharacter=XY,Mn.friendlyAttrValue=zY,Mn.escapeAttrValue=BY,Mn.onIgnoreTagStripAll=eQe,Mn.StripTagBody=tQe,Mn.stripCommentTag=nQe,Mn.stripBlankChar=rQe,Mn.attributeWrapSign='"',Mn.cssFilter=CY,Mn.getDefaultCSSWhiteList=zRe;var Ey={},gc=lQ;function iQe(e){var t=gc.spaceIndex(e),n;return t===-1?n=e.slice(1,-1):n=e.slice(1,t+1),n=gc.trim(n).toLowerCase(),n.slice(0,1)==="/"&&(n=n.slice(1)),n.slice(-1)==="/"&&(n=n.slice(0,-1)),n}function aQe(e){return e.slice(0,2)===""||s===l-1){r+=n(e.slice(i,a)),u=e.slice(a,s+1),c=iQe(u),r+=t(a,r.length,c,u,aQe(u)),i=s+1,a=!1;continue}if(d==='"'||d==="'")for(var O=1,f=e.charAt(s-O);f.trim()===""||f==="=";){if(f==="="){o=d;continue e}f=e.charAt(s-++O)}}else if(d===o){o=!1;continue}}return i0;t--){var n=e[t];if(n!==" ")return n==="="?t:-1}}function OQe(e){return e[0]==='"'&&e[e.length-1]==='"'||e[0]==="'"&&e[e.length-1]==="'"}function FY(e){return OQe(e)?e.substr(1,e.length-2):e}Ey.parseTag=oQe,Ey.parseAttr=lQe;var fQe=sQ.FilterCSS,Xa=Mn,WY=Ey,pQe=WY.parseTag,hQe=WY.parseAttr,Ty=lQ;function wy(e){return e==null}function mQe(e){var t=Ty.spaceIndex(e);if(t===-1)return{html:"",closing:e[e.length-2]==="/"};e=Ty.trim(e.slice(t+1,-1));var n=e[e.length-1]==="/";return n&&(e=Ty.trim(e.slice(0,-1))),{html:e,closing:n}}function gQe(e){var t={};for(var n in e)t[n]=e[n];return t}function _Qe(e){var t={};for(var n in e)Array.isArray(e[n])?t[n.toLowerCase()]=e[n].map(function(r){return r.toLowerCase()}):t[n.toLowerCase()]=e[n];return t}function VY(e){e=gQe(e||{}),e.stripIgnoreTag&&(e.onIgnoreTag&&console.error('Notes: cannot use these two options "stripIgnoreTag" and "onIgnoreTag" at the same time'),e.onIgnoreTag=Xa.onIgnoreTagStripAll),e.whiteList||e.allowList?e.whiteList=_Qe(e.whiteList||e.allowList):e.whiteList=Xa.whiteList,this.attributeWrapSign=e.singleQuotedAttributeValue===!0?"'":Xa.attributeWrapSign,e.onTag=e.onTag||Xa.onTag,e.onTagAttr=e.onTagAttr||Xa.onTagAttr,e.onIgnoreTag=e.onIgnoreTag||Xa.onIgnoreTag,e.onIgnoreTagAttr=e.onIgnoreTagAttr||Xa.onIgnoreTagAttr,e.safeAttrValue=e.safeAttrValue||Xa.safeAttrValue,e.escapeHtml=e.escapeHtml||Xa.escapeHtml,this.options=e,e.css===!1?this.cssFilter=!1:(e.css=e.css||{},this.cssFilter=new fQe(e.css))}VY.prototype.process=function(e){if(e=e||"",e=e.toString(),!e)return"";var t=this,n=t.options,r=n.whiteList,i=n.onTag,a=n.onIgnoreTag,o=n.onTagAttr,s=n.onIgnoreTagAttr,l=n.safeAttrValue,c=n.escapeHtml,u=t.attributeWrapSign,d=t.cssFilter;n.stripBlankChar&&(e=Xa.stripBlankChar(e)),n.allowCommentTag||(e=Xa.stripCommentTag(e));var O=!1;n.stripIgnoreTagBody&&(O=Xa.StripTagBody(n.stripIgnoreTagBody,a),a=O.onIgnoreTag);var f=pQe(e,function(p,h,m,g,_){var b={sourcePosition:p,position:h,isClosing:_,isWhite:Object.prototype.hasOwnProperty.call(r,m)},y=i(m,g,b);if(!wy(y))return y;if(b.isWhite){if(b.isClosing)return"";var v=mQe(g),E=r[m],w=hQe(v.html,function(T,S){var x=Ty.indexOf(E,T)!==-1,$=o(m,T,S,x);return wy($)?x?(S=l(m,T,S,d),S?T+"="+u+S+u:T):($=s(m,T,S,x),wy($)?void 0:$):$});return g="<"+m,w&&(g+=" "+w),v.closing&&(g+=" /"),g+=">",g}else return y=a(m,g,b),wy(y)?c(g):y},c);return O&&(f=O.remove(f)),f};var bQe=VY;(function(e,t){var n=Mn,r=Ey,i=bQe;function a(s,l){var c=new i(l);return c.process(s)}t=e.exports=a,t.filterXSS=a,t.FilterXSS=i,function(){for(var s in n)t[s]=n[s];for(var l in r)t[l]=r[l]}(),typeof window<"u"&&(window.filterXSS=e.exports);function o(){return typeof self<"u"&&typeof DedicatedWorkerGlobalScope<"u"&&self instanceof DedicatedWorkerGlobalScope}o()&&(self.filterXSS=e.exports)})($Y,$Y.exports);const yQe={class:"relative w-4 h-4 cursor-pointer"},vQe={class:"relative w-4 h-4"},SQe=20*1024*1024,EQe=3,TQe=dp({__name:"Index2",props:{editorId:String,modelValue:String,modelModifiers:Object,autoDetectCode:{type:Boolean,default:!0}},emits:["update:modelValue","isUploading"],setup(e,{emit:t}){const n=["r","q","w","n","m","s","o","g",",","=","+","-",".","p","c","b","m","`","f","Enter","Backspace"],r=["bold","italic","underline","title","-","quote","code","table",1,"-","mermaid","katex","-","=","preview",0],i=xe(null),a=xe(null),o=xe(!1),s=()=>{o.value=!o.value,o.value?(T0.request(),document.querySelectorAll('[role="dialog"]').forEach(y=>y.style.display="none"),document.querySelector("body").style["pointer-events"]="auto"):(T0.exit(),document.querySelectorAll('[role="dialog"]').forEach(y=>y.style.display="block"),document.querySelector("body").style["pointer-events"]="none")},c=xe(e.modelValue),u=t,d=()=>{u("update:modelValue",c)},O=y=>{n.includes(y.key)&&y.stopPropagation()},f=y=>{document.addEventListener("keydown",O,!0)},p=y=>{document.removeEventListener("keydown",O,!0)},h=["image/jpeg","image/png","image/gif","image/webp"],m=async(y,v=0)=>{var E;try{const w=await nce(y);if(!((E=w.data)!=null&&E.url))throw new Error("Upload response missing URL");return w.data.url}catch(w){if(console.error(`Upload attempt ${v+1} failed:`,w),vsetTimeout(T,1e3*(v+1))),m(y,v+1);throw w}},g=async y=>{b([y.target.files[0]],v=>{v.forEach(E=>{i.value.insert(()=>({targetValue:`![image](${E})`,select:!1,deviationStart:0,deviationEnd:0})),c.value+=`![image](${E})`,d()})})},_=async y=>{b([y.target.files[0]],v=>{v.forEach(E=>{a.value.insert(()=>({targetValue:`![image](${E})`,select:!1,deviationStart:0,deviationEnd:0})),c.value+=`![image](${E})`,d()})})},b=async(y,v)=>{if(y.filter(T=>!h.includes(T.type)).length>0){Ut.warning("Only image files allowed (jpg, png, gif, webp)");return}if(y.filter(T=>T.size>SQe).length>0){Ut.warning("Image size cannot exceed 20MB");return}try{u("isUploading",!0);const T=[];for(let S=0;S(fe(),qe(Pt,null,[te(D(Mh),{editorId:e.editorId,modelValue:c.value,"onUpdate:modelValue":v[0]||(v[0]=E=>c.value=E),theme:"dark",toolbars:r,ref_key:"editorRef",ref:i,autoDetectCode:!0,language:"en-US",preview:!1,onInput:d,style:{height:"200px"},onOnUploadImg:b,onOnFocus:f,onOnBlur:p},{defToolbars:ce(()=>[te(D(hc),{title:"fullscreen",onOnClick:s},{trigger:ce(()=>[te(D(IN),{class:"w-4 h-4 mt-1"})]),_:1}),te(D(hc),{title:"image"},{trigger:ce(()=>[$e("div",yQe,[$e("input",{onChange:g,type:"file",class:"absolute w-4 h-4 left-0 top-0 cursor-pointer opacity-0"},null,32),te(D(AN),{class:"w-4 h-4 cursor-pointer"})])]),_:1})]),_:1},8,["editorId","modelValue"]),o.value?(fe(),Se(gd,{key:0,to:"body"},[te(D(Mh),{modelValue:c.value,"onUpdate:modelValue":v[1]||(v[1]=E=>c.value=E),theme:"dark",autoDetectCode:!0,editorId:`full-${e.editorId}`,toolbars:r,ref_key:"editorRefFull",ref:a,language:"en-US",pageFullscreen:!0,class:"fixed top-0 left-0 w-[100vw] h-[100vh] z-12000",onInput:d,onOnUploadImg:b,onOnFocus:f,onOnBlur:p},{defToolbars:ce(()=>[te(D(hc),{title:"fullscreen",onOnClick:s},{trigger:ce(()=>[te(D(IN),{class:"w-4 h-4 mt-1"})]),_:1}),te(D(hc),{title:"image"},{trigger:ce(()=>[$e("div",vQe,[$e("input",{onChange:_,type:"file",class:"absolute w-4 h-4 left-0 top-0 cursor-pointer opacity-0"},null,32),te(D(AN),{class:"w-4 h-4"})])]),_:1})]),_:1},8,["modelValue","editorId"])])):kt("",!0)],64))}},[["__scopeId","data-v-071fa62a"]]),wQe={class:"px-6 pb-6"},xQe={class:"bg-[#353535] z-1 px-6 py-4 w-full rounded-tl-lg rounded-tr-lg custom-shadow border-t-[1px] flex justify-between relative"},$Qe={key:0},PQe={key:1},RQe={class:"bg-[#353535] px-6 pb-4"},QQe={class:"flex items-center space-x-2 mt-2"},kQe={class:"flex h-28 items-center justify-end relative"},CQe={key:0,class:"absolute top-2 left-1 text-xs"},AQe={key:1,class:"flex-1"},IQe={class:"text-center pt-2"},DQe={key:0,class:"pl-2"},NQe={class:"bg-[#353535] px-6 w-full h-14 rounded-tl-lg rounded-tr-lg custom-shadow border-t-[1px] flex justify-between items-center -mt-4"},MQe={key:0,class:"z-50 w-full h-full absolute left-0 top-0"},LQe=ve({__name:"index",setup(e){const t=lp(),n=su(),r=xe(!0),i=xe([{value:"",label:""}]),a=xe([{value:"",label:""}]),o=xe({...n.modelDetail}),s=xe(-1),l=xe(!1),c=S=>{s.value=S,r.value&&(r.value=!1)},u=Ie(()=>o.value.versions.map(x=>x.progress).some((x,$)=>x!==100&&o.value.versions[$].file_upload_id));function d(S,x){o.value.versions&&(o.value.versions[x].public=S)}let O;async function f(S){if(!await t_({title:"Are you sure you want to delete this version?",desc:"This action cannot be undone.",cancel:"No, Keep It",continue:"Yes, Delete It",z:"z-9000"}))return;const $={...o.value};s.value===$.versions.length-1&&(s.value=Number(s.value)-1),$.versions=$.versions||[],$.versions.splice(S,1),n.setModelDetail($),$.versions.length===1&&(s.value=0),$.versions.length===0&&(r.value=!0)}function p(){const S={...o.value};S.versions=S.versions||[],S.versions.push({version:"",base_model:"",intro:"",public:!1,filePath:"",sign:"",path:""}),n.setModelDetail(S),r.value=!1,s.value=S.versions.length-1}function h(){if(!o.value.name){Ut.error("Please enter the model name"),o.value.nameError=!0;return}if(!o.value.type){Ut.error("Please select the model type"),o.value.typeError=!0;return}o.value.versions.length?(s.value=0,r.value=!1):p()}function m(){const S={...o.value};S.versions=S.versions||[];for(let x=0;xx.version&&x.base_model&&x.sign)}const g=(S,x)=>{o.value.versions[x].progress=S},_=(S,x)=>{o.value.versions[x].path=S},b=S=>{o.value.versions[S].filePathError=!1},y=(S,x)=>{o.value.versions[x].sign=S.sha256sum,o.value.versions[x].filePathError=!1},v=S=>{o.value.versions[S].progress&&delete o.value.versions[S].progress},E=(S,x)=>{S.speed&&(o.value.versions[x].speed=S.speed),S.fileName&&(o.value.versions[x].fileName=S.fileName)};async function w(){if(!m())return;l.value=!0,setTimeout(()=>{l.value=!1},5e3);const S={...o.value};S.versions.forEach(x=>{delete x.baseModelError,delete x.filePath,delete x.filePathError,delete x.versionError,delete x.speed,delete x.fileName}),S.id?await oce(S):await ace(S),Ut.success("Model published successfully"),T()}const T=()=>{n.setDialogStatus(!1,0),n.clearModelDetail(),r.value=!0,l.value=!1,n.uploadModelDone()};return Be(()=>t.socketMessage,S=>{if(S.type=="progress"){const x=o.value.versions.findIndex($=>$.file_upload_id==S.data.upload_id);o.value.versions[x].progress=Number(S.data.progress.replace("%",""))}if(S.type=="status"&&S.data.status=="finish"){const x=o.value.versions.findIndex($=>$.file_upload_id==S.data.upload_id);o.value.versions[x]&&(o.value.versions[x].path=S.data.model_files[0].path,o.value.versions[x].sign=S.data.model_files[0].sign)}if(S.type=="interrupted"){Ut.success("Upload interrupted");const x=o.value.versions.findIndex($=>$.file_upload_id==S.data.upload_id);delete o.value.versions[x].progress,o.value.versions[x].filePath=""}if(S.type=="error"){Ut.error(S.data.message);const x=o.value.versions.findIndex($=>$.file_upload_id==S.data.upload_id);delete o.value.versions[x].progress,o.value.versions[x].filePath=""}if(S.type=="prepared"&&O.close(),S.type==="errors"&&S.data&&S.data.code===500101){O.close(),Ut.error(S.data.message);const x=o.value.versions.findIndex($=>$.file_upload_id==S.data.data.upload_id);o.value.versions[x].progress&&delete o.value.versions[x].progress,o.value.versions[x].filePath=""}},{deep:!0}),Be(()=>n.modelDetail,S=>{o.value=S},{deep:!0}),Be(()=>n.showVersionId,S=>{const x=o.value.versions.findIndex($=>$.id==S);setTimeout(()=>{s.value=x}),x!=-1&&(r.value=!1)},{deep:!0}),ht(async()=>{const S=await b2();i.value=S.data;const x=await _2();a.value=x.data}),(S,x)=>(fe(),qe(Pt,null,[$e("div",{onClick:x[0]||(x[0]=$=>D(n).setDialogStatus(!0)),class:"flex items-center hover:bg-[#4A238E] cursor-pointer relative px-3"},x[7]||(x[7]=[$e("svg",{xmlns:"http://www.w3.org/2000/svg",width:"1rem",height:"1rem",viewBox:"0 0 24 24"},[$e("path",{fill:"none",stroke:"#ddd","stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"1.5",d:"M21 16.008V7.99a1.98 1.98 0 0 0-1-1.717l-7-4.008a2.02 2.02 0 0 0-2 0L4 6.273c-.619.355-1 1.01-1 1.718v8.018c0 .709.381 1.363 1 1.717l7 4.008a2.02 2.02 0 0 0 2 0l7-4.008c.619-.355 1-1.01 1-1.718M12 22V12m0 0l8.73-5.04m-17.46 0L12 12"})],-1),$e("span",{class:"block leading h-full leading-8 text-sm"},"Publish",-1)])),D(n).showDialog?(fe(),Se(n_,{key:0,open:D(n).showDialog,"onUpdate:open":x[6]||(x[6]=$=>D(n).showDialog=$),onOnClose:T,class:"px-0 overflow-hidden pb-0 z-9000",layoutClass:"z-9000",contentClass:"custom-scrollbar max-h-[80vh] overflow-y-auto w-full rounded-tl-lg rounded-tr-lg custom-shadow"},ZK({title:ce(()=>[$e("span",{class:"px-6 cursor-pointer",onClick:x[1]||(x[1]=$=>{s.value=-1,r.value=!0})},"Publish a Model")]),default:ce(()=>[Ja($e("div",wQe,[te(ou,{label:"Model Name"},{default:ce(()=>[te(D(cp),{onChange:x[2]||(x[2]=$=>o.value.nameError=!1),class:xt({"border-red-500":o.value.nameError}),type:"text",placeholder:"Enter Model Name","model-value":o.value.name,"onUpdate:modelValue":x[3]||(x[3]=$=>o.value.name=$)},null,8,["class","model-value"])]),_:1}),te(ou,{label:"Model Type"},{default:ce(()=>[te(u2,{"onUpdate:open":x[4]||(x[4]=$=>o.value.typeError=!1),class:xt({"border-red-500":o.value.typeError}),"model-value":o.value.type,"onUpdate:modelValue":x[5]||(x[5]=$=>o.value.type=$),placeholder:"Select Model Type"},{default:ce(()=>[(fe(!0),qe(Pt,null,Oi(i.value,($,Q)=>(fe(),Se(D(l2),{key:Q,value:$.value},{default:ce(()=>[ot(Ot($.label),1)]),_:2},1032,["value"]))),128))]),_:1},8,["class","model-value"])]),_:1}),te(D(Ur),{class:"w-full mt-3",onClick:h},{default:ce(()=>x[8]||(x[8]=[ot("Next Step")])),_:1})],512),[[Ds,r.value]]),te(Tle,{multiple:!0,activeIndex:s.value},{default:ce(()=>[(fe(!0),qe(Pt,null,Oi(o.value.versions,($,Q)=>(fe(),Se(wle,{key:Q,index:Q,onToggle:c},{title:ce(()=>[$e("div",xQe,[s.value!==Q&&$.version?(fe(),qe("span",$Qe,Ot($.version),1)):(fe(),qe("span",PQe,"Add Version")),o.value.versions.length!==1?(fe(),Se(D(Eoe),{key:2,class:"w-4 h-4",onClickCapture:Sr(k=>f(Q),["stop"])},null,8,["onClickCapture"])):kt("",!0),$.progress&&s.value&&s.value!==Q?(fe(),Se(D(c2),{key:3,"model-value":$.progress,class:"absolute w-full bottom-0 left-0 h-1"},null,8,["model-value"])):kt("",!0)])]),default:ce(()=>[$e("div",RQe,[te(ou,{label:"Version Name"},{default:ce(()=>[te(D(cp),{onChange:k=>$.versionError=!1,class:xt({"border-red-500":$.versionError}),type:"text",placeholder:"Version Name","model-value":$.version,"onUpdate:modelValue":k=>$.version=k},null,8,["onChange","class","model-value","onUpdate:modelValue"])]),_:2},1024),te(ou,{label:"Base Model"},{default:ce(()=>[te(u2,{"onUpdate:open":k=>$.baseModelError=!1,class:xt({"border-red-500":$.baseModelError}),"model-value":$.base_model,"onUpdate:modelValue":k=>$.base_model=k,placeholder:"Select Base Model"},{default:ce(()=>[(fe(!0),qe(Pt,null,Oi(a.value,(k,P)=>(fe(),Se(D(l2),{key:P,value:k.value},{default:ce(()=>[ot(Ot(k.label),1)]),_:2},1032,["value"]))),128))]),_:2},1032,["onUpdate:open","class","model-value","onUpdate:modelValue"])]),_:2},1024),te(ou,{label:"Introduction"},{default:ce(()=>[te(TQe,{modelValue:$.intro,"onUpdate:modelValue":k=>$.intro=k,modelModifiers:{modelValue:!0},editorId:`myeditor${Q}`},null,8,["modelValue","onUpdate:modelValue","editorId"])]),_:2},1024),te(ou,{label:""},{default:ce(()=>[$e("div",QQe,[te(D(Ole),{id:"airplane-mode",checked:$.public,"onUpdate:checked":[k=>$.public=k,k=>{d(k,Q)}]},null,8,["checked","onUpdate:checked"]),te(D(dle),{for:"airplane-mode"},{default:ce(()=>x[9]||(x[9]=[ot("Publicly Visible")])),_:1})])]),_:2},1024),Ja(te(ou,{label:"File"},{default:ce(()=>[$e("div",kQe,[$.progress&&$.fileName?(fe(),qe("p",CQe,Ot($.fileName),1)):kt("",!0),$.progress?(fe(),qe("div",AQe,[te(D(c2),{"model-value":$.progress,class:"mt-4 h-3"},null,8,["model-value"]),$e("p",IQe,[ot(Ot($.progress)+"% Uploaded ",1),$.speed?(fe(),qe("span",DQe,"Speed: "+Ot($.speed),1)):kt("",!0)])])):kt("",!0),te(fce,{parallel:1,ref_for:!0,ref:$.ref,chunkSize:1,class:xt({"border-red-500":$.filePathError}),onPath:k=>_(k,Q),onStart:()=>b(Q),onSuccess:k=>y(k,Q),onError:()=>v(Q),onUploadInfo:k=>E(k,Q),onProgress:k=>g(k,Q)},null,8,["class","onPath","onStart","onSuccess","onError","onUploadInfo","onProgress"])])]),_:2},1536),[[Ds,!$.showUpload]])])]),_:2},1032,["index"]))),128))]),_:1},8,["activeIndex"]),l.value?(fe(),qe("div",MQe)):kt("",!0)]),_:2},[r.value?void 0:{name:"foot",fn:ce(()=>[$e("div",NQe,[te(D(Ur),{variant:"outline",class:"",onClick:p},{default:ce(()=>x[10]||(x[10]=[ot("Add Version")])),_:1}),te(D(Ur),{disabled:u.value,onClick:w},{default:ce(()=>x[11]||(x[11]=[ot("Publish")])),_:1},8,["disabled"])])]),key:"0"}]),1032,["open"])):kt("",!0)],64))}}),UQe=ve({__name:"index",setup(e){const t=xe({"Remote Folders":"1",Upload:"2"});return fetch("api/bizyair/news",{method:"GET"}).then(n=>n.json()).then(n=>{t.value=n}),(n,r)=>(fe(),Se(NN,{show_cases:t.value,buttonText:"News",icon:"book-open",isJson:!0},{default:ce(()=>r[0]||(r[0]=[$e("svg",{xmlns:"http://www.w3.org/2000/svg",width:"1rem",height:"1rem",viewBox:"0 0 32 32"},[$e("path",{fill:"#ddd",d:"M11 23a1 1 0 1 0 0 2h10a1 1 0 1 0 0-2zm-1-3a1 1 0 0 1 1-1h10a1 1 0 1 1 0 2H11a1 1 0 0 1-1-1m1-5a1 1 0 1 0 0 2h10a1 1 0 1 0 0-2zM5 5a3 3 0 0 1 3-3h10.172a3 3 0 0 1 2.12.879l5.83 5.828A3 3 0 0 1 27 10.828V27a3 3 0 0 1-3 3H8a3 3 0 0 1-3-3zm3-1a1 1 0 0 0-1 1v22a1 1 0 0 0 1 1h16a1 1 0 0 0 1-1V12h-5a3 3 0 0 1-3-3V4zm12 6h4.586L19 4.414V9a1 1 0 0 0 1 1"})],-1)])),_:1},8,["show_cases"]))}}),XQe={class:"comfy-modal-content-sml"},zQe={class:"py-2"},BQe=ve({__name:"apiKeyDialog",setup(e){const t=lp(),n=xe(""),r=xe(!1),i=async c=>{const f=window.open("https://account.siliconflow.cn/oauth?client_id=SFaJLLq0y6CAMoyDm81aMu","oauthPopup","width=600,height=600");window.addEventListener("message",p=>{p.data.length>0&&p.data[0].secretKey!==void 0&&(c(p.data[0].secretKey),f&&f.close())})};function a(){r.value=!1}async function o(){if(!n.value)return r.value=!0,!1;const c=await hse(`api_key=${encodeURIComponent(n.value)}`);c.ok?(Ut("API Key set successfully!"),t.handleApiKeyDialog(!1),t.loginRefresh()):Ut.error(`Failed to set API Key: ${await c.text()}`)}function s(){t.handleApiKeyDialog(!1),n.value="",r.value=!1}function l(){i(c=>{n.value=c})}return(c,u)=>(fe(),Se(n_,{open:D(t).showApiKeyDialog,"onUpdate:open":u[1]||(u[1]=d=>D(t).showApiKeyDialog=d),layoutClass:"z-9000",class:"max-w-[680px] z-9000",onOnClose:u[2]||(u[2]=d=>D(t).handleApiKeyDialog(!1))},{title:ce(()=>u[3]||(u[3]=[ot("Set API Key")])),foot:ce(()=>[te(D(Ur),{type:"submit",onClick:o},{default:ce(()=>u[8]||(u[8]=[ot("Submit")])),_:1}),te(D(Ur),{variant:"outline",onClick:s},{default:ce(()=>u[9]||(u[9]=[ot("Close")])),_:1})]),default:ce(()=>[$e("div",XQe,[te(D(cp),{modelValue:n.value,"onUpdate:modelValue":u[0]||(u[0]=d=>n.value=d),type:"password",placeholder:"API Key",class:xt([{"border-red-500":r.value}]),onInput:a},null,8,["modelValue","class"]),$e("p",zQe,[u[4]||(u[4]=ot(" Please ")),$e("a",{class:"underline",href:"###",onClick:Sr(l,["prevent"])},"click to login"),u[5]||(u[5]=ot(" and autofill the key, "))]),u[6]||(u[6]=$e("p",{class:"py-2"},[ot(" or visit "),$e("a",{class:"underline",href:"https://cloud.siliconflow.cn",target:"_blank"},"https://cloud.siliconflow.cn"),ot(" to get your key and input manually. ")],-1)),u[7]||(u[7]=$e("p",{class:"py-2"},[ot(" Setting the API Key signifies agreement to the "),$e("a",{class:"underline",href:"https://docs.siliconflow.cn/docs/user-agreement",target:"_blank"},"User Agreement"),ot(" and "),$e("a",{class:"underline",href:"https://docs.siliconflow.cn/docs/privacy-policy",target:"_blank"},"Privacy Policy.")],-1))])]),_:1},8,["open"]))}}),FQe={class:"shadcn-root flex w-full"},WQe=ve({__name:"App",setup(e){const t=lp();return t.loginRefresh(),t.sendSocket(),(n,r)=>(fe(),qe("div",FQe,[te(Moe),D(t).isLogin?(fe(),Se(nle,{key:0})):(fe(),Se(Tse,{key:1})),te(LQe),te(UQe),te(BQe)]))}}),YY=ve({__name:"Tabs",props:{defaultValue:{},orientation:{},dir:{},activationMode:{},modelValue:{},asChild:{type:Boolean},as:{}},emits:["update:modelValue"],setup(e,{emit:t}){const i=nn(e,t);return(a,o)=>(fe(),Se(D(vae),Nt(Lt(D(i))),{default:ce(()=>[we(a.$slots,"default")]),_:3},16))}}),VQe=ve({__name:"TabsContent",props:{value:{},forceMount:{type:Boolean},asChild:{type:Boolean},as:{},class:{}},setup(e){const t=e,n=Ie(()=>{const{class:r,...i}=t;return i});return(r,i)=>(fe(),Se(D(Eae),Ue({class:D(dt)("mt-2 ring-offset-background focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2",t.class)},n.value),{default:ce(()=>[we(r.$slots,"default")]),_:3},16,["class"]))}}),jY=ve({__name:"TabsList",props:{loop:{type:Boolean},asChild:{type:Boolean},as:{},class:{}},setup(e){const t=e,n=Ie(()=>{const{class:r,...i}=t;return i});return(r,i)=>(fe(),Se(D(Sae),Ue(n.value,{class:D(dt)("inline-flex items-center justify-center rounded-md bg-muted p-1 text-muted-foreground",t.class)}),{default:ce(()=>[we(r.$slots,"default")]),_:3},16,["class"]))}}),YQe={class:"truncate"},qY=ve({__name:"TabsTrigger",props:{value:{},disabled:{type:Boolean},asChild:{type:Boolean},as:{},class:{}},setup(e){const t=e,n=Ie(()=>{const{class:i,...a}=t;return a}),r=Gr(n);return(i,a)=>(fe(),Se(D(Tae),Ue(D(r),{class:D(dt)("inline-flex items-center justify-center whitespace-nowrap rounded-sm px-3 py-1.5 text-sm font-medium ring-offset-background transition-all focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50 data-[state=active]:bg-background data-[state=active]:text-foreground data-[state=active]:shadow-sm",t.class)}),{default:ce(()=>[$e("span",YQe,[we(i.$slots,"default")])]),_:3},16,["class"]))}}),cQ=ve({__name:"Badge",props:{variant:{},class:{}},setup(e){const t=e;return(n,r)=>(fe(),qe("div",{class:xt(D(dt)(D(jQe)({variant:n.variant}),t.class))},[we(n.$slots,"default")],2))}}),jQe=g0("inline-flex items-center rounded-full border px-2.5 py-0.5 text-xs font-semibold transition-colors focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2",{variants:{variant:{default:"border-transparent bg-primary text-primary-foreground hover:bg-primary/80",secondary:"border-transparent bg-secondary text-secondary-foreground hover:bg-secondary/80",destructive:"border-transparent bg-destructive text-destructive-foreground hover:bg-destructive/80",outline:"text-foreground"}},defaultVariants:{variant:"default"}}),xy=ve({__name:"Popover",props:{defaultOpen:{type:Boolean},open:{type:Boolean},modal:{type:Boolean}},emits:["update:open"],setup(e,{emit:t}){const i=nn(e,t);return(a,o)=>(fe(),Se(D(Oie),Nt(Lt(D(i))),{default:ce(()=>[we(a.$slots,"default")]),_:3},16))}}),$y=ve({inheritAttrs:!1,__name:"PopoverContent",props:{forceMount:{type:Boolean},trapFocus:{type:Boolean},side:{},sideOffset:{default:4},align:{default:"center"},alignOffset:{},avoidCollisions:{type:Boolean},collisionBoundary:{},collisionPadding:{},arrowPadding:{},sticky:{},hideWhenDetached:{type:Boolean},updatePositionStrategy:{},prioritizePosition:{type:Boolean},asChild:{type:Boolean},as:{},disableOutsidePointerEvents:{type:Boolean},class:{}},emits:["escapeKeyDown","pointerDownOutside","focusOutside","interactOutside","openAutoFocus","closeAutoFocus"],setup(e,{emit:t}){const n=e,r=t,i=Ie(()=>{const{class:o,...s}=n;return s}),a=nn(i,r);return(o,s)=>(fe(),Se(D(pie),null,{default:ce(()=>[te(D(gie),Ue({...D(a),...o.$attrs},{class:D(dt)("z-50 w-72 rounded-md border bg-popover p-4 text-popover-foreground shadow-md outline-none data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",n.class)}),{default:ce(()=>[we(o.$slots,"default")]),_:3},16,["class"])]),_:3}))}}),Py=ve({__name:"PopoverTrigger",props:{asChild:{type:Boolean},as:{}},setup(e){const t=e;return(n,r)=>(fe(),Se(D(fie),Nt(Lt(t)),{default:ce(()=>[we(n.$slots,"default")]),_:3},16))}}),Ry=ve({__name:"Command",props:{modelValue:{default:""},defaultValue:{},open:{type:Boolean,default:!0},defaultOpen:{type:Boolean},searchTerm:{},selectedValue:{},multiple:{type:Boolean},disabled:{type:Boolean},name:{},dir:{},filterFunction:{},displayValue:{},resetSearchTermOnBlur:{type:Boolean},asChild:{type:Boolean},as:{},class:{}},emits:["update:modelValue","update:open","update:searchTerm","update:selectedValue"],setup(e,{emit:t}){const n=e,r=t,i=Ie(()=>{const{class:o,...s}=n;return s}),a=nn(i,r);return(o,s)=>(fe(),Se(D(cre),Ue(D(a),{class:D(dt)("flex h-full w-full flex-col overflow-hidden rounded-md bg-popover text-popover-foreground",n.class)}),{default:ce(()=>[we(o.$slots,"default")]),_:3},16,["class"]))}}),Uh=ve({__name:"CommandGroup",props:{asChild:{type:Boolean},as:{},class:{},heading:{}},setup(e){const t=e,n=Ie(()=>{const{class:r,...i}=t;return i});return(r,i)=>(fe(),Se(D(dre),Ue(n.value,{class:D(dt)("overflow-hidden p-1 text-foreground [&_[cmdk-group-heading]]:px-2 [&_[cmdk-group-heading]]:py-1.5 [&_[cmdk-group-heading]]:text-xs [&_[cmdk-group-heading]]:font-medium [&_[cmdk-group-heading]]:text-muted-foreground",t.class)}),{default:ce(()=>[r.heading?(fe(),Se(D(Ore),{key:0,class:"px-2 py-1.5 text-xs font-medium text-muted-foreground"},{default:ce(()=>[ot(Ot(r.heading),1)]),_:1})):kt("",!0),we(r.$slots,"default")]),_:3},16,["class"]))}}),cl=ve({__name:"CommandItem",props:{value:{},disabled:{type:Boolean},asChild:{type:Boolean},as:{},class:{}},emits:["select"],setup(e,{emit:t}){const n=e,r=t,i=Ie(()=>{const{class:o,...s}=n;return s}),a=nn(i,r);return(o,s)=>(fe(),Se(D(_re),Ue(D(a),{class:D(dt)("relative flex cursor-default select-none items-center rounded-sm px-2 py-1.5 text-sm outline-none data-[highlighted]:bg-accent data-[highlighted]:text-accent-foreground data-[disabled]:pointer-events-none data-[disabled]:opacity-50",n.class)}),{default:ce(()=>[we(o.$slots,"default")]),_:3},16,["class"]))}}),qQe={role:"presentation"},Qy=ve({__name:"CommandList",props:{forceMount:{type:Boolean},position:{},bodyLock:{type:Boolean},dismissable:{type:Boolean,default:!1},side:{},sideOffset:{},align:{},alignOffset:{},avoidCollisions:{type:Boolean},collisionBoundary:{},collisionPadding:{},arrowPadding:{},sticky:{},hideWhenDetached:{type:Boolean},updatePositionStrategy:{},prioritizePosition:{type:Boolean},asChild:{type:Boolean},as:{},disableOutsidePointerEvents:{type:Boolean},class:{}},emits:["escapeKeyDown","pointerDownOutside","focusOutside","interactOutside"],setup(e,{emit:t}){const n=e,r=t,i=Ie(()=>{const{class:o,...s}=n;return s}),a=nn(i,r);return(o,s)=>(fe(),Se(D(hre),Ue(D(a),{class:D(dt)("max-h-[300px] overflow-y-auto overflow-x-hidden",n.class)}),{default:ce(()=>[$e("div",qQe,[we(o.$slots,"default")])]),_:3},16,["class"]))}}),uQ=ve({__name:"CommandSeparator",props:{asChild:{type:Boolean},as:{},class:{}},setup(e){const t=e,n=Ie(()=>{const{class:r,...i}=t;return i});return(r,i)=>(fe(),Se(D(bre),Ue(n.value,{class:D(dt)("-mx-1 h-px bg-border",t.class)}),{default:ce(()=>[we(r.$slots,"default")]),_:3},16,["class"]))}}),GQe={class:"flex space-x-2 mb-4"},ZQe={class:"relative flex-1"},HQe={class:"flex flex-wrap gap-2"},KQe={class:"flex flex-wrap gap-2"},JQe=ve({__name:"ModelFilterBar",props:{showSortPopover:{type:Boolean}},emits:["update:showSortPopover","fetchData"],setup(e,{emit:t}){const n=su(),r=xe([]),i=t,a=c=>{n.filterState.sort=c,i("fetchData"),i("update:showSortPopover",!1)},o=c=>{if(n.selectedBaseModels.length!==0)return;const u=[...n.filterState.model_types],d=u.indexOf(c);d===-1?u.push(c):u.splice(d,1),n.filterState.model_types=u,i("fetchData"),i("update:showSortPopover",!1)},s=c=>{const u=[...n.filterState.base_models],d=u.indexOf(c);d===-1?u.push(c):u.splice(d,1),n.filterState.base_models=u,i("fetchData"),i("update:showSortPopover",!1)},l=()=>{n.modelListPathParams.current=1,i("fetchData"),i("update:showSortPopover",!1)};return ht(async()=>{n.selectedBaseModels&&(r.value=[...n.selectedBaseModels])}),(c,u)=>{const d=GK("debounce");return fe(),qe("div",GQe,[$e("div",ZQe,[Ja(te(D(cp),{modelValue:D(n).filterState.keyword,"onUpdate:modelValue":u[0]||(u[0]=O=>D(n).filterState.keyword=O),placeholder:"Filter by name",class:"h-[44px] border border-[#9CA3AF] w-full bg-[#222] rounded-lg pr-8 pl-8"},null,8,["modelValue"]),[[d,l]]),u[5]||(u[5]=$e("span",{class:"absolute start-0 inset-y-0 flex items-center justify-center px-2"},[$e("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 16 16",fill:"none",class:"hover:brightness-150 transition-all duration-300"},[$e("path",{d:"M14 14L11.1333 11.1333M12.6667 7.33333C12.6667 10.2789 10.2789 12.6667 7.33333 12.6667C4.38781 12.6667 2 10.2789 2 7.33333C2 4.38781 4.38781 2 7.33333 2C10.2789 2 12.6667 4.38781 12.6667 7.33333Z",stroke:"#F9FAFB","stroke-linecap":"round","stroke-linejoin":"round"})])],-1))]),te(D(xy),{class:"bg-[#353535]",open:c.showSortPopover,"onUpdate:open":u[4]||(u[4]=O=>i("update:showSortPopover",O))},{default:ce(()=>[te(D(Py),{class:"bg-transparent"},{default:ce(()=>[te(D(Ur),{variant:"default",class:"w-[44px] h-[44px] hover:border-2 hover:border-white cursor-pointer group"},{default:ce(()=>u[6]||(u[6]=[$e("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 16 16",fill:"none"},[$e("path",{d:"M2 10.6667L4.66667 13.3334M4.66667 13.3334L7.33333 10.6667M4.66667 13.3334V2.66675M7.33333 2.66675H14M7.33333 5.33341H12M7.33333 8.00008H10",stroke:"#F9FAFB","stroke-linecap":"round","stroke-linejoin":"round"})],-1)])),_:1})]),_:1}),te(D($y),{side:"bottom",align:"end",class:"w-[150px] p-0 bg-[#353535] rounded-lg z-12000"},{default:ce(()=>[te(D(Ry),null,{default:ce(()=>[te(D(Qy),null,{default:ce(()=>[te(D(Uh),null,{default:ce(()=>[te(D(cl),{value:"recently",onClick:u[1]||(u[1]=O=>a("Recently")),class:xt(["px-2 py-1.5 text-[#F9FAFB] cursor-pointer [&:hover]:!bg-[#6D28D9] [&:hover]:!text-[#F9FAFB]",D(n).filterState.sort==="Recently"?"!bg-[#6D28D9] !text-[#F9FAFB]":""])},{default:ce(()=>u[7]||(u[7]=[ot(" Recently ")])),_:1},8,["class"]),["my","my_fork"].includes(D(n).mode)?kt("",!0):(fe(),Se(D(cl),{key:0,value:"most-forked",onClick:u[2]||(u[2]=O=>a("Most Forked")),class:xt(["px-2 py-1.5 text-[#F9FAFB] cursor-pointer [&:hover]:!bg-[#6D28D9] [&:hover]:!text-[#F9FAFB]",D(n).filterState.sort==="Most Forked"?"!bg-[#6D28D9] !text-[#F9FAFB]":""])},{default:ce(()=>u[8]||(u[8]=[ot(" Most Forked ")])),_:1},8,["class"])),["my","my_fork"].includes(D(n).mode)?kt("",!0):(fe(),Se(D(cl),{key:1,value:"most-used",onClick:u[3]||(u[3]=O=>a("Most Used")),class:xt(["px-2 py-1.5 text-[#F9FAFB] cursor-pointer [&:hover]:!bg-[#6D28D9] [&:hover]:!text-[#F9FAFB]",D(n).filterState.sort==="Most Used"?"!bg-[#6D28D9] !text-[#F9FAFB]":""])},{default:ce(()=>u[9]||(u[9]=[ot(" Most Used ")])),_:1},8,["class"]))]),_:1})]),_:1})]),_:1})]),_:1})]),_:1},8,["open"]),te(D(xy),null,{default:ce(()=>[te(D(Py),{class:"bg-transparent"},{default:ce(()=>[te(D(Ur),{variant:"default",class:"w-[44px] h-[44px] hover:border-2 hover:border-white cursor-pointer"},{default:ce(()=>u[10]||(u[10]=[$e("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 16 16",fill:"none",class:"mr-2"},[$e("path",{d:"M14.6666 2H1.33325L6.66658 8.30667V12.6667L9.33325 14V8.30667L14.6666 2Z",stroke:"#F9FAFB","stroke-linecap":"round","stroke-linejoin":"round"})],-1)])),_:1})]),_:1}),te(D($y),{side:"bottom",align:"end",class:"w-[200px] p-0 bg-[#222] rounded-lg z-12000"},{default:ce(()=>[te(D(Ry),null,{default:ce(()=>[te(D(Qy),null,{default:ce(()=>[te(D(Uh),null,{default:ce(()=>[u[11]||(u[11]=$e("div",{class:"p-2"},[$e("div",{class:"text-sm font-medium text-[#F9FAFB] mb-2"},"Model Types")],-1)),te(D(cl),{value:"model-types",class:"p-2"},{default:ce(()=>[$e("div",HQe,[(fe(!0),qe(Pt,null,Oi(D(n).modelTypes,O=>(fe(),Se(D(cQ),{variant:"secondary",key:O.value,onClick:f=>o(O.value),class:xt(["cursor-not-allowed hover:!bg-inherit",D(n).filterState.model_types.includes(O.value)?"bg-[#6D28D9] hover:!bg-[#6D28D9]":"bg-[#4E4E4E] hover:!bg-[#4E4E4E]"])},{default:ce(()=>[ot(Ot(O.label),1)]),_:2},1032,["onClick","class"]))),128))])]),_:1})]),_:1}),te(D(uQ)),te(D(Uh),null,{default:ce(()=>[u[12]||(u[12]=$e("div",{class:"p-2"},[$e("div",{class:"text-sm font-medium text-[#F9FAFB] mb-2"},"Base Models")],-1)),te(D(cl),{value:"base-models",class:"p-2"},{default:ce(()=>[$e("div",KQe,[(fe(!0),qe(Pt,null,Oi(D(n).baseModelTypes.filter(O=>{var f,p;return((f=D(n).selectedBaseModels)==null?void 0:f.length)===0||((p=D(n).selectedBaseModels)==null?void 0:p.includes(O.value))}),O=>(fe(),Se(D(cQ),{variant:"secondary",key:O.value,onClick:f=>s(O.value),class:xt(["cursor-pointer hover:!bg-inherit",D(n).filterState.base_models.includes(O.value)?"bg-[#6D28D9] hover:!bg-[#6D28D9]":"bg-[#4E4E4E] hover:!bg-[#4E4E4E]"])},{default:ce(()=>[ot(Ot(O.label),1)]),_:2},1032,["onClick","class"]))),128))])]),_:1})]),_:1})]),_:1})]),_:1})]),_:1})]),_:1})])}}}),eke=ve({__name:"PaginationEllipsis",props:{asChild:{type:Boolean},as:{},class:{}},setup(e){const t=e,n=Ie(()=>{const{class:r,...i}=t;return i});return(r,i)=>(fe(),Se(D(nie),Ue(n.value,{class:D(dt)("w-9 h-9 flex items-center justify-center",t.class)}),{default:ce(()=>[we(r.$slots,"default",{},()=>[te(D(yoe))])]),_:3},16,["class"]))}}),tke=ve({__name:"PaginationFirst",props:{asChild:{type:Boolean,default:!0},as:{},class:{}},setup(e){const t=e,n=Ie(()=>{const{class:r,...i}=t;return i});return(r,i)=>(fe(),Se(D(rie),Nt(Lt(n.value)),{default:ce(()=>[te(D(Ur),{class:xt(D(dt)("w-10 h-10 p-0",t.class)),variant:"outline"},{default:ce(()=>[we(r.$slots,"default",{},()=>[te(D(moe),{class:"h-4 w-4"})])]),_:3},8,["class"])]),_:3},16))}}),nke=ve({__name:"PaginationLast",props:{asChild:{type:Boolean,default:!0},as:{},class:{}},setup(e){const t=e,n=Ie(()=>{const{class:r,...i}=t;return i});return(r,i)=>(fe(),Se(D(iie),Nt(Lt(n.value)),{default:ce(()=>[te(D(Ur),{class:xt(D(dt)("w-10 h-10 p-0",t.class)),variant:"outline"},{default:ce(()=>[we(r.$slots,"default",{},()=>[te(D(goe),{class:"h-4 w-4"})])]),_:3},8,["class"])]),_:3},16))}}),rke=ve({__name:"PaginationNext",props:{asChild:{type:Boolean,default:!0},as:{},class:{}},setup(e){const t=e,n=Ie(()=>{const{class:r,...i}=t;return i});return(r,i)=>(fe(),Se(D(cie),Nt(Lt(n.value)),{default:ce(()=>[te(D(Ur),{class:xt(D(dt)("w-10 h-10 p-0",t.class)),variant:"outline"},{default:ce(()=>[we(r.$slots,"default",{},()=>[te(D(CN),{class:"h-4 w-4"})])]),_:3},8,["class"])]),_:3},16))}}),ike=ve({__name:"PaginationPrev",props:{asChild:{type:Boolean,default:!0},as:{},class:{}},setup(e){const t=e,n=Ie(()=>{const{class:r,...i}=t;return i});return(r,i)=>(fe(),Se(D(uie),Nt(Lt(n.value)),{default:ce(()=>[te(D(Ur),{class:xt(D(dt)("w-10 h-10 p-0",t.class)),variant:"outline"},{default:ce(()=>[we(r.$slots,"default",{},()=>[te(D(poe),{class:"h-4 w-4"})])]),_:3},8,["class"])]),_:3},16))}}),ake={key:0},oke=dp(ve({__name:"ModelPagination",setup(e){const t=su(),n=Ie(()=>t.modelListPathParams.total/t.modelListPathParams.page_size>1),r=i=>{t.updatePagination(i)};return(i,a)=>n.value?(fe(),qe("div",ake,[te(D(tie),{total:D(t).modelListPathParams.total,"items-per-page":D(t).modelListPathParams.page_size,"default-page":D(t).modelListPathParams.current,"sibling-count":1,"show-edges":"","onUpdate:page":r},{default:ce(({page:o})=>[te(D(sie),{class:"flex items-center gap-1"},{default:ce(({items:s})=>[te(D(tke),{class:"pagination-button"}),te(D(ike),{class:"pagination-button"}),(fe(!0),qe(Pt,null,Oi(s,(l,c)=>(fe(),qe(Pt,null,[l.type==="page"?(fe(),Se(D(lie),{key:c,value:l.value,"as-child":""},{default:ce(()=>[te(D(Ur),{class:"pagination-button page-button",variant:l.value===o?"default":"ghost"},{default:ce(()=>[ot(Ot(l.value),1)]),_:2},1032,["variant"])]),_:2},1032,["value"])):(fe(),Se(D(eke),{key:l.type,index:c,class:"pagination-button"},null,8,["index"]))],64))),256)),te(D(rke),{class:"pagination-button"}),te(D(nke),{class:"pagination-button"})]),_:2},1024)]),_:1},8,["total","items-per-page","default-page"])])):kt("",!0)}}),[["__scopeId","data-v-654ff384"]]),ske={class:"relative w-full overflow-auto"},lke=ve({__name:"Table",props:{class:{}},setup(e){const t=e;return(n,r)=>(fe(),qe("div",ske,[$e("table",{class:xt(D(dt)("w-full caption-bottom text-sm",t.class))},[we(n.$slots,"default")],2)]))}}),cke=ve({__name:"TableBody",props:{class:{}},setup(e){const t=e;return(n,r)=>(fe(),qe("tbody",{class:xt(D(dt)("[&_tr:last-child]:border-0",t.class))},[we(n.$slots,"default")],2))}}),Os=ve({__name:"TableCell",props:{class:{}},setup(e){const t=e;return(n,r)=>(fe(),qe("td",{class:xt(D(dt)("p-4 align-middle [&:has([role=checkbox])]:pr-0",t.class))},[we(n.$slots,"default")],2))}}),Xh=ve({__name:"TableRow",props:{class:{}},setup(e){const t=e;return(n,r)=>(fe(),qe("tr",{class:xt(D(dt)("border-b transition-colors hover:bg-muted/50 data-[state=selected]:bg-muted",t.class))},[we(n.$slots,"default")],2))}}),ky=ve({__name:"TableHead",props:{class:{}},setup(e){const t=e;return(n,r)=>(fe(),qe("th",{class:xt(D(dt)("h-12 px-4 text-left align-middle font-medium text-muted-foreground [&:has([role=checkbox])]:pr-0",t.class))},[we(n.$slots,"default")],2))}}),uke=ve({__name:"TableHeader",props:{class:{}},setup(e){const t=e;return(n,r)=>(fe(),qe("thead",{class:xt(D(dt)("[&_tr]:border-b",t.class))},[we(n.$slots,"default")],2))}}),GY=ve({__name:"ScrollBar",props:{orientation:{default:"vertical"},forceMount:{type:Boolean},asChild:{type:Boolean},as:{},class:{}},setup(e){const t=e,n=Ie(()=>{const{class:r,...i}=t;return i});return(r,i)=>(fe(),Se(D(Die),Ue(n.value,{class:D(dt)("flex touch-none select-none transition-colors",r.orientation==="vertical"&&"h-full w-2.5 border-l border-l-transparent p-px",r.orientation==="horizontal"&&"h-2.5 flex-col border-t border-t-transparent p-px",t.class)}),{default:ce(()=>[te(D(Nie),{class:"relative flex-1 rounded-full bg-border"})]),_:1},16,["class"]))}}),dke=ve({__name:"ScrollArea",props:{type:{},dir:{},scrollHideDelay:{},asChild:{type:Boolean},as:{},class:{}},setup(e){const t=e,n=Ie(()=>{const{class:r,...i}=t;return i});return(r,i)=>(fe(),Se(D(wie),Ue(n.value,{class:D(dt)("relative overflow-hidden",t.class)}),{default:ce(()=>[te(D(xie),{class:"h-full w-full rounded-[inherit]"},{default:ce(()=>[we(r.$slots,"default")]),_:3}),te(GY),te(D(Lie))]),_:3},16,["class"]))}}),Oke=ve({__name:"Avatar",props:{class:{},size:{default:"sm"},shape:{default:"circle"}},setup(e){const t=e;return(n,r)=>(fe(),Se(D(Hne),{class:xt(D(dt)(D(hke)({size:n.size,shape:n.shape}),t.class))},{default:ce(()=>[we(n.$slots,"default")]),_:3},8,["class"]))}}),fke=ve({__name:"AvatarFallback",props:{delayMs:{},asChild:{type:Boolean},as:{}},setup(e){const t=e;return(n,r)=>(fe(),Se(D(ere),Nt(Lt(t)),{default:ce(()=>[we(n.$slots,"default")]),_:3},16))}}),pke=ve({__name:"AvatarImage",props:{src:{},asChild:{type:Boolean},as:{}},setup(e){const t=e;return(n,r)=>(fe(),Se(D(Jne),Ue(t,{class:"h-full w-full object-cover"}),null,16))}}),hke=g0("inline-flex items-center justify-center font-normal text-foreground select-none shrink-0 bg-secondary overflow-hidden",{variants:{size:{sm:"h-10 w-10 text-xs",base:"h-16 w-16 text-2xl",lg:"h-32 w-32 text-5xl"},shape:{circle:"rounded-full",square:"rounded-md"}}}),mke={key:0,class:"p-6 pb-12 flex flex-col gap-4 items-start justify-start min-w-[1000px] relative shadow-[0px_20px_40px_0px_rgba(0,0,0,0.25)]"},gke={class:"flex flex-col gap-1.5 items-start justify-start self-stretch shrink-0 relative"},_ke={class:"flex flex-row gap-2 items-center justify-start self-stretch shrink-0 relative"},bke={class:"text-text-text-foreground text-left font-['Inter-SemiBold',_sans-serif] text-lg leading-[18px] font-semibold relative",style:{"letter-spacing":"-0.025em"}},yke={class:"flex flex-row gap-1 items-start justify-start shrink-0 relative"},vke={class:"bg-[#6D28D933] rounded-radius-rounded-xl pr-1.5 pl-1.5 flex flex-row gap-1 items-center justify-center shrink-0 min-w-[40px] relative overflow-hidden"},Ske={class:"text-text-text-foreground text-left font-['Inter-Regular',_sans-serif] text-sm leading-5 font-normal relative flex-1"},Eke={class:"bg-[#6D28D933] rounded-radius-rounded-xl pr-1.5 pl-1.5 flex flex-row gap-1 items-center justify-center shrink-0 min-w-[40px] relative overflow-hidden"},Tke={class:"text-text-text-foreground text-left font-['Inter-Regular',_sans-serif] text-sm leading-5 font-normal relative flex-1"},wke={class:"bg-[#6D28D933] rounded-radius-rounded-xl pr-1.5 pl-1.5 flex flex-row gap-1 items-center justify-center shrink-0 min-w-[40px] relative overflow-hidden"},xke={class:"text-text-text-foreground text-left font-['Inter-Regular',_sans-serif] text-sm leading-5 font-normal relative flex-1"},$ke={class:"flex flex-row gap-1 items-center justify-start self-stretch shrink-0 relative"},Pke={class:"bg-[#4e4e4e] rounded-lg p-1 flex flex-row gap-4 items-start justify-start self-stretch shrink-0 relative"},Rke={class:"min-w-[200px] max-w-[600px]"},Qke={class:"whitespace-nowrap"},kke={class:"flex gap-8"},Cke={class:"flex flex-row gap-4 items-start justify-start shrink-0 relative"},Ake={class:"text-text-text-muted-foreground text-left font-['Inter-Regular',_sans-serif] text-xs leading-5 font-normal relative"},Ike={class:"text-text-text-muted-foreground text-left font-['Inter-Regular',_sans-serif] text-xs leading-5 font-normal relative"},Dke={class:"flex flex-row gap-8 items-start justify-start self-stretch flex-1 relative"},Nke={class:"flex flex-col gap-4 items-start justify-start relative min-w-[620px] w-[65%] overflow-hidden"},Mke={class:"w-full min-h-[80vh]"},Lke={key:1,class:"w-full h-[80vh] bg-[#353535] rounded-tl-lg rounded-tr-lg"},Uke={class:"flex flex-col gap-6 items-start justify-start w-[40%] relative"},Xke={class:"pb-8 flex flex-col gap-6 items-start justify-start shrink-0 h-[97px] relative"},zke={class:"flex flex-row gap-2 items-center justify-start shrink-0 relative"},Bke={class:"flex flex-row gap-1.5 items-start justify-start self-stretch shrink-0 relative"},Fke={class:"rounded-[6px] border-solid border-[rgba(78,78,78,0.50)] border flex flex-col gap-0 items-start justify-start self-stretch shrink-0 relative text-[#F9FAFB] font-inter text-sm font-medium leading-5"},Wke={className:"flex w-full text-gray-300 text-sm"},Vke={className:"flex-1 p-4 border-b text-sm border-[rgba(78,78,78,0.50)]"},Yke={className:"flex w-full"},jke={className:"flex-1 p-4 border-b border-[rgba(78,78,78,0.50)]"},qke={className:"flex w-full"},Gke={className:"flex-1 p-4 border-b border-[rgba(78,78,78,0.50)]"},Zke={className:"flex w-full"},Hke={className:"flex-1 p-4 border-b border-[rgba(78,78,78,0.50)] flex items-center gap-2"},Kke={className:"flex w-full"},Jke={className:"flex-1 p-4 border-b border-[rgba(78,78,78,0.50)] flex flex-row gap-2"},eCe={class:"bg-[#6D28D933] rounded-radius-rounded-xl pr-1.5 pl-1.5 flex flex-row gap-1 items-center justify-center shrink-0 min-w-[40px] relative overflow-hidden"},tCe={class:"text-text-text-foreground text-left font-['Inter-Regular',_sans-serif] text-sm leading-5 font-normal relative flex-1"},nCe={class:"bg-[#6D28D933] rounded-radius-rounded-xl pr-1.5 pl-1.5 flex flex-row gap-1 items-center justify-center shrink-0 min-w-[40px] relative overflow-hidden"},rCe={class:"text-text-text-foreground text-left font-['Inter-Regular',_sans-serif] text-sm leading-5 font-normal relative flex-1"},iCe={class:"bg-[#6D28D933] rounded-radius-rounded-xl pr-1.5 pl-1.5 flex flex-row gap-1 items-center justify-center shrink-0 min-w-[40px] relative overflow-hidden"},aCe={class:"text-text-text-foreground text-left font-['Inter-Regular',_sans-serif] text-sm leading-5 font-normal relative flex-1"},oCe={class:"rounded-md border-solid border-[#4e4e4e] border flex flex-col gap-0 items-start justify-start self-stretch shrink-0 relative"},sCe={class:"flex px-[8px] py-4 items-center self-stretch text-[#F9FAFB] font-inter text-xs font-medium leading-5"},lCe=dp(ve({__name:"Index",props:{modelId:{},version:{}},setup(e){const t=su(),n=xe(),r=xe(),i=xe(!1),a=xe(null),o=e,s=async()=>{const b=await y2({id:o.modelId,source:t.mode});if(!b.data){Ut.error("Model not found."),t.closeAndReload();return}n.value=b.data,l()},l=()=>{var b;if(n.value&&n.value.versions&&n.value.versions.length>0)if((b=o.version)!=null&&b.id){const y=n.value.versions.find(v=>v.id===o.version.id);y&&(r.value={...y},bt(()=>{var v;p((v=o.version)==null?void 0:v.id)}))}else r.value={...n.value.versions[0]},bt(()=>{var y;(y=r.value)!=null&&y.id&&p(r.value.id)})};ht(async()=>{await s()});const c=b=>{var v,E;const y=(E=(v=n.value)==null?void 0:v.versions)==null?void 0:E.find(w=>w.id===b);y&&(r.value=y)},u=()=>{i.value=!i.value},d=async()=>{var b;await sce((b=r.value)==null?void 0:b.id),s()},O=async()=>{var b;await lce((b=r.value)==null?void 0:b.id),await s()},f=b=>{bt(()=>{setTimeout(()=>{if(!a.value)return;const y=a.value.$el.querySelector("[data-radix-scroll-area-viewport]"),v=y==null?void 0:y.querySelector('[role="tablist"]'),E=v==null?void 0:v.querySelector(`[role="tab"].version-tab-${b}`);if(!y||!E||!v)return;const T=Array.from(v.querySelectorAll('[role="tab"]')).reduce((k,P)=>k+P.offsetWidth,0);v.style.width=`${T}px`;const S=E.offsetLeft,x=y.clientWidth,$=E.offsetWidth,Q=Math.max(0,S-(x-$)/2);y.scrollTo({left:Q,behavior:"smooth"})},100)})},p=b=>{setTimeout(()=>{f(b)},200)},h=async(b,y)=>{var v,E,w;if(b==="edit"&&(t.setModelDetail(n),t.setDialogStatus(!0,Number((v=r.value)==null?void 0:v.id)),i.value=!1),b==="remove"){if(i.value=!1,!await t_({title:"Are you sure you want to delete this model?",desc:"This action cannot be undone.",cancel:"No, Keep It",continue:"Yes, Delete It",z:"z-9000"}))return;if((E=n.value)!=null&&E.versions&&((w=n.value)==null?void 0:w.versions.some(x=>x.public))){Ut.warning("Model has public version, cannot remove.");return}m(y)}},m=async b=>{try{await v2(b),Ut.success("Model removed successfully."),t.reload+=1}catch(y){Ut.error("Failed to remove model."),console.error("Error removing model:",y)}},g=()=>{r.value&&n.value&&t.setApplyObject(r.value,n.value)},_=async b=>{try{if(navigator.clipboard)await navigator.clipboard.writeText(b||""),Ut.success("Copied successfully.");else{const y=document.createElement("input");y.value=b||"",document.body.appendChild(y),y.select(),document.execCommand("copy"),document.body.removeChild(y)}}catch{Ut.error("Copy failed.")}};return(b,y)=>{var v,E,w,T,S,x,$,Q,k,P,R,C,I,X,F,z,J,ne,re,Z,W,j,q,G,ie,le,ae,pe,K,A,N;return n.value?(fe(),qe("div",mke,[$e("div",gke,[$e("div",_ke,[$e("div",bke,Ot(D(pE)((v=n.value)==null?void 0:v.name,60)),1),$e("div",yke,[$e("div",vke,[y[3]||(y[3]=$e("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 16 16",fill:"none"},[$e("path",{d:"M3.33325 2L12.6666 8L3.33325 14V2Z",stroke:"#F9FAFB","stroke-linecap":"round","stroke-linejoin":"round"})],-1)),$e("div",Ske,Ot(D(vd)((w=(E=n.value)==null?void 0:E.counter)==null?void 0:w.used_count)),1)])]),$e("div",Eke,[y[4]||(y[4]=$e("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 16 16",fill:"none"},[$e("path",{d:"M7.99992 1.33325L10.0599 5.50659L14.6666 6.17992L11.3333 9.42659L12.1199 14.0133L7.99992 11.8466L3.87992 14.0133L4.66659 9.42659L1.33325 6.17992L5.93992 5.50659L7.99992 1.33325Z",stroke:"#F9FAFB","stroke-linecap":"round","stroke-linejoin":"round"})],-1)),$e("div",Tke,Ot(D(vd)((S=(T=n.value)==null?void 0:T.counter)==null?void 0:S.forked_count)),1)]),$e("div",wke,[y[5]||(y[5]=mg('',1)),$e("div",xke,Ot(D(vd)(($=(x=n.value)==null?void 0:x.counter)==null?void 0:$.liked_count)),1)])]),$e("div",$ke,[$e("div",Pke,[$e("div",Rke,[te(D(dke),{ref_key:"scrollViewportRef",ref:a,class:"rounded-md w-full"},{default:ce(()=>{var M,oe;return[$e("div",Qke,[te(D(YY),{defaultValue:(M=r.value)==null?void 0:M.id,value:(oe=r.value)==null?void 0:oe.id},{default:ce(()=>[te(D(jY),{class:"inline-flex h-12 bg-transparent text-sm text-white w-auto"},{default:ce(()=>{var se;return[(fe(!0),qe(Pt,null,Oi((se=n.value)==null?void 0:se.versions,V=>(fe(),Se(D(qY),{value:V.id,onClick:ee=>c(V.id),class:xt([["version-tab",`version-tab-${V.id}`],"text-sm t bg-[#9CA3AF] data-[state=active]:bg-[#7C3AED] h-10 px-3 py-2 mx-1"])},{default:ce(()=>[ot(Ot(V.version),1)]),_:2},1032,["value","onClick","class"]))),256))]}),_:1})]),_:1},8,["defaultValue","value"])]),te(D(GY),{orientation:"horizontal"})]}),_:1},512)])]),y[10]||(y[10]=$e("div",{class:"text-text-text-muted-foreground text-left font-['Inter-Regular',_sans-serif] text-xs leading-5 font-normal relative flex-1"},null,-1)),$e("div",kke,[(fe(),qe("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 16 16",fill:"none",class:"cursor-pointer",onClick:d,style:Ei({stroke:(Q=r.value)!=null&&Q.liked?"#6D28D9":"#F9FAFB",fill:(k=r.value)!=null&&k.liked?"#6D28D9":"none"})},y[6]||(y[6]=[$e("g",{"clip-path":"url(#clip0_440_1289)"},[$e("path",{d:"M4.66659 6.66658V14.6666M9.99992 3.91992L9.33325 6.66658H13.2199C13.4269 6.66658 13.6311 6.71478 13.8162 6.80735C14.0013 6.89992 14.1624 7.03432 14.2866 7.19992C14.4108 7.36551 14.4947 7.55775 14.5317 7.7614C14.5688 7.96506 14.5579 8.17454 14.4999 8.37325L12.9466 13.7066C12.8658 13.9835 12.6974 14.2268 12.4666 14.3999C12.2358 14.573 11.9551 14.6666 11.6666 14.6666H2.66659C2.31296 14.6666 1.97382 14.5261 1.72378 14.2761C1.47373 14.026 1.33325 13.6869 1.33325 13.3333V7.99992C1.33325 7.6463 1.47373 7.30716 1.72378 7.05711C1.97382 6.80706 2.31296 6.66658 2.66659 6.66658H4.50659C4.75464 6.66645 4.99774 6.59713 5.20856 6.4664C5.41937 6.33567 5.58953 6.14873 5.69992 5.92659L7.99992 1.33325C8.3143 1.33715 8.62374 1.41203 8.90512 1.55232C9.1865 1.6926 9.43254 1.89466 9.62486 2.14339C9.81717 2.39212 9.9508 2.68109 10.0157 2.98872C10.0807 3.29635 10.0753 3.61468 9.99992 3.91992Z","stroke-linecap":"round","stroke-linejoin":"round"})],-1),$e("defs",null,[$e("clipPath",{id:"clip0_440_1289"},[$e("rect",{width:"16",height:"16",fill:"white"})])],-1)]),4)),D(t).mode==="my"||D(t).mode==="my_fork"?(fe(),Se(D(xy),{key:0,class:"bg-[#353535]",open:i.value,"onUpdate:open":u},{default:ce(()=>[te(D(Py),{class:"bg-transparent"},{default:ce(()=>y[7]||(y[7]=[$e("div",{class:"flex justify-center items-center rounded-md w-8 relative z-50"},[$e("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 16 16",fill:"none",class:"cursor-pointer"},[$e("path",{d:"M8.66659 7.99992C8.66659 7.63173 8.36811 7.33325 7.99992 7.33325C7.63173 7.33325 7.33325 7.63173 7.33325 7.99992C7.33325 8.36811 7.63173 8.66659 7.99992 8.66659C8.36811 8.66659 8.66659 8.36811 8.66659 7.99992Z",stroke:"#F9FAFB","stroke-linecap":"round","stroke-linejoin":"round"}),$e("path",{d:"M8.66659 3.33325C8.66659 2.96506 8.36811 2.66658 7.99992 2.66658C7.63173 2.66658 7.33325 2.96506 7.33325 3.33325C7.33325 3.70144 7.63173 3.99992 7.99992 3.99992C8.36811 3.99992 8.66659 3.70144 8.66659 3.33325Z",stroke:"#F9FAFB","stroke-linecap":"round","stroke-linejoin":"round"}),$e("path",{d:"M8.66659 12.6666C8.66659 12.2984 8.36811 11.9999 7.99992 11.9999C7.63173 11.9999 7.33325 12.2984 7.33325 12.6666C7.33325 13.0348 7.63173 13.3333 7.99992 13.3333C8.36811 13.3333 8.66659 13.0348 8.66659 12.6666Z",stroke:"#F9FAFB","stroke-linecap":"round","stroke-linejoin":"round"})])],-1)])),_:1}),te(D($y),{side:"bottom",align:"end",class:"w-[150px] p-0 bg-[#353535] rounded-lg group-hover:visible z-15000"},{default:ce(()=>[te(D(Ry),null,{default:ce(()=>[te(D(Qy),null,{default:ce(()=>[te(D(Uh),null,{default:ce(()=>[te(D(cl),{value:"edit",onClick:y[0]||(y[0]=M=>{var oe;return h("edit",(oe=n.value)==null?void 0:oe.id)}),class:"px-2 py-1.5 mb-1 text-[#F9FAFB] cursor-pointer [&:hover]:!bg-[#6D28D9] [&:hover]:!text-[#F9FAFB]"},{default:ce(()=>y[8]||(y[8]=[ot(" Edit ")])),_:1}),te(D(uQ)),te(D(cl),{value:"remove",onClick:y[1]||(y[1]=M=>{var oe;return h("remove",(oe=n.value)==null?void 0:oe.id)}),class:"px-2 py-1.5 mb-1 mt-1 text-[#F9FAFB] cursor-pointer [&:hover]:!bg-[#6D28D9] [&:hover]:!text-[#F9FAFB]"},{default:ce(()=>y[9]||(y[9]=[ot(" Remove ")])),_:1})]),_:1})]),_:1})]),_:1})]),_:1})]),_:1},8,["open"])):kt("",!0)])]),$e("div",Cke,[$e("div",Ake," First Published: "+Ot((P=r.value)==null?void 0:P.created_at),1),$e("div",Ike," Last Updated: "+Ot((R=r.value)==null?void 0:R.updated_at),1)])]),$e("div",Dke,[$e("div",Nke,[$e("div",Mke,[(C=r.value)!=null&&C.intro?(fe(),Se(D(Lp),{key:0,id:"previewRef",modelValue:(I=r.value)==null?void 0:I.intro,noImgZoomIn:!0,preview:!0,theme:"dark",class:"bg-[#353535] w-full min-h-[80vh]"},null,8,["modelValue"])):(fe(),qe("div",Lke,y[11]||(y[11]=[$e("div",{class:"flex justify-center items-center h-full"},[$e("div",{class:"text-text-text-muted-foreground text-left font-['Inter-Regular',_sans-serif] text-xs leading-5 font-normal relative"}," No introduction yet ")],-1)])))])]),$e("div",Uke,[$e("div",Xke,[$e("div",zke,[te(D(Oke),null,{default:ce(()=>[te(D(pke),{src:"https://github.com/radix-vue.png",alt:"@radix-vue"}),te(D(fke),null,{default:ce(()=>{var M,oe;return[ot(Ot((oe=(M=n.value)==null?void 0:M.user_name)==null?void 0:oe.slice(0,2)),1)]}),_:1})]),_:1}),ot(" "+Ot((X=n.value)==null?void 0:X.user_name),1)]),$e("div",Bke,[D(t).mode==="publicity"?(fe(),Se(D(Ur),{key:0,variant:"default",class:"w-[124px] flex h-9 px-3 py-2 justify-center items-center gap-2 flex-1 rounded-md bg-[#6D28D9]",onClick:O,disabled:(F=r.value)==null?void 0:F.forked},{default:ce(()=>{var M;return[ot(Ot((M=r.value)!=null&&M.forked?"Forked":"Fork"),1)]}),_:1},8,["disabled"])):kt("",!0),te(D(Ur),{onClick:g,class:"flex w-[170px] px-8 py-2 justify-center items-center gap-2 bg-[#F43F5E] hover:bg-[#F43F5E]/90 rounded-[6px]"},{default:ce(()=>y[12]||(y[12]=[$e("svg",{xmlns:"http://www.w3.org/2000/svg",width:"17",height:"16",viewBox:"0 0 17 16",fill:"none"},[$e("path",{d:"M6.49988 7.9999L7.83322 9.33324L10.4999 6.66657M3.06655 5.74657C2.96925 5.30825 2.98419 4.85246 3.10999 4.42146C3.23579 3.99046 3.46838 3.5982 3.7862 3.28105C4.10401 2.9639 4.49676 2.73213 4.92802 2.60723C5.35929 2.48233 5.81511 2.46835 6.25322 2.56657C6.49436 2.18944 6.82655 1.87907 7.21919 1.66409C7.61182 1.44911 8.05225 1.33643 8.49988 1.33643C8.94752 1.33643 9.38795 1.44911 9.78058 1.66409C10.1732 1.87907 10.5054 2.18944 10.7466 2.56657C11.1853 2.46792 11.6419 2.48184 12.0739 2.60704C12.5058 2.73225 12.8991 2.96466 13.2171 3.28267C13.5351 3.60068 13.7675 3.99395 13.8927 4.4259C14.0179 4.85786 14.0319 5.31446 13.9332 5.75324C14.3104 5.99437 14.6207 6.32657 14.8357 6.7192C15.0507 7.11183 15.1634 7.55227 15.1634 7.9999C15.1634 8.44754 15.0507 8.88797 14.8357 9.2806C14.6207 9.67323 14.3104 10.0054 13.9332 10.2466C14.0314 10.6847 14.0175 11.1405 13.8926 11.5718C13.7677 12.003 13.5359 12.3958 13.2187 12.7136C12.9016 13.0314 12.5093 13.264 12.0783 13.3898C11.6473 13.5156 11.1915 13.5305 10.7532 13.4332C10.5124 13.8118 10.1799 14.1235 9.78663 14.3394C9.39333 14.5554 8.9519 14.6686 8.50322 14.6686C8.05453 14.6686 7.6131 14.5554 7.2198 14.3394C6.8265 14.1235 6.49404 13.8118 6.25322 13.4332C5.81511 13.5315 5.35929 13.5175 4.92802 13.3926C4.49676 13.2677 4.10401 13.0359 3.7862 12.7188C3.46838 12.4016 3.23579 12.0093 3.10999 11.5783C2.98419 11.1473 2.96925 10.6916 3.06655 10.2532C2.68652 10.0127 2.37349 9.68002 2.15658 9.28605C1.93967 8.89207 1.82593 8.44964 1.82593 7.9999C1.82593 7.55016 1.93967 7.10773 2.15658 6.71376C2.37349 6.31979 2.68652 5.98707 3.06655 5.74657Z",stroke:"#F9FAFB","stroke-linecap":"round","stroke-linejoin":"round"})],-1),ot("Apply")])),_:1})])]),$e("div",Fke,[$e("div",Wke,[y[13]||(y[13]=$e("div",{className:"w-[100px] bg-[#4E4E4E80] p-4 border-b border-[rgba(78,78,78,0.50)]"}," Type",-1)),$e("div",Vke,[$e("span",{class:xt(`${(z=n.value)==null?void 0:z.type} inline-flex px-[10px] py-[2px] items-start gap-[10px] rounded-[9999px] relative overflow-hidden`)},Ot((J=n.value)==null?void 0:J.type),3)])]),$e("div",Yke,[y[14]||(y[14]=$e("div",{className:"w-[100px] bg-[#4E4E4E80] p-4 text-sm border-b border-[rgba(78,78,78,0.50)] whitespace-nowrap"}," Base Model",-1)),$e("div",jke,Ot((ne=r.value)==null?void 0:ne.base_model),1)]),$e("div",qke,[y[15]||(y[15]=$e("div",{className:"w-[100px] bg-[#4E4E4E80] p-4 border-b border-[rgba(78,78,78,0.50)]"}," Published",-1)),$e("div",Gke,Ot((re=r.value)==null?void 0:re.created_at),1)]),$e("div",Zke,[y[17]||(y[17]=$e("div",{className:"w-[100px] bg-[#4E4E4E80] p-4 border-b border-[rgba(78,78,78,0.50)]"}," Hash",-1)),$e("div",Hke,[$e("span",null,Ot((Z=r.value)!=null&&Z.sign?D(pE)((W=r.value)==null?void 0:W.sign,15):""),1),(j=r.value)!=null&&j.sign?(fe(),qe("svg",{key:0,xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 16 16",fill:"none",class:"cursor-pointer hover:opacity-80",onClick:y[2]||(y[2]=M=>{var oe;return _(((oe=r.value)==null?void 0:oe.sign)||"")})},y[16]||(y[16]=[$e("g",{"clip-path":"url(#clip0_315_3710)"},[$e("path",{d:"M2.66659 10.6666C1.93325 10.6666 1.33325 10.0666 1.33325 9.33325V2.66659C1.33325 1.93325 1.93325 1.33325 2.66659 1.33325H9.33325C10.0666 1.33325 10.6666 1.93325 10.6666 2.66659M6.66658 5.33325H13.3333C14.0696 5.33325 14.6666 5.93021 14.6666 6.66658V13.3333C14.6666 14.0696 14.0696 14.6666 13.3333 14.6666H6.66658C5.93021 14.6666 5.33325 14.0696 5.33325 13.3333V6.66658C5.33325 5.93021 5.93021 5.33325 6.66658 5.33325Z",stroke:"#9CA3AF","stroke-linecap":"round","stroke-linejoin":"round"})],-1),$e("defs",null,[$e("clipPath",{id:"clip0_315_3710"},[$e("rect",{width:"16",height:"16",fill:"white"})])],-1)]))):kt("",!0)])]),$e("div",Kke,[y[21]||(y[21]=$e("div",{className:"w-[100px] bg-[#4E4E4E80] p-4 text-gray-300 border-b border-[rgba(78,78,78,0.50)]"}," Stats",-1)),$e("div",Jke,[$e("div",eCe,[y[18]||(y[18]=$e("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 16 16",fill:"none"},[$e("path",{d:"M3.33325 2L12.6666 8L3.33325 14V2Z",stroke:"#F9FAFB","stroke-linecap":"round","stroke-linejoin":"round"})],-1)),$e("div",tCe,Ot(D(vd)((G=(q=r.value)==null?void 0:q.counter)==null?void 0:G.used_count)),1)]),$e("div",nCe,[y[19]||(y[19]=$e("svg",{xmlns:"http://www.w3.org/2000/svg",width:"16",height:"16",viewBox:"0 0 16 16",fill:"none"},[$e("path",{d:"M7.99992 1.33325L10.0599 5.50659L14.6666 6.17992L11.3333 9.42659L12.1199 14.0133L7.99992 11.8466L3.87992 14.0133L4.66659 9.42659L1.33325 6.17992L5.93992 5.50659L7.99992 1.33325Z",stroke:"#F9FAFB","stroke-linecap":"round","stroke-linejoin":"round"})],-1)),$e("div",rCe,Ot(D(vd)((le=(ie=r.value)==null?void 0:ie.counter)==null?void 0:le.forked_count)),1)]),$e("div",iCe,[y[20]||(y[20]=mg('',1)),$e("div",aCe,Ot(D(vd)((pe=(ae=r.value)==null?void 0:ae.counter)==null?void 0:pe.liked_count)),1)])])])]),$e("div",oCe,[y[22]||(y[22]=$e("div",{class:"bg-[#424242] rounded-md flex items-center justify-start self-stretch shrink-0 relative h-[44px] pl-2"}," File ",-1)),$e("div",sCe,Ot((K=r.value)!=null&&K.file_name?D(pE)((A=r.value)==null?void 0:A.file_name,20):"")+" ("+Ot(D(Cee)((N=r.value)==null?void 0:N.file_size))+") ",1)])])])])):kt("",!0)}}}),[["__scopeId","data-v-1848d10c"]]),cCe={class:"text-sm text-white-500 flex items-center min-w-0"},uCe={class:"truncate flex-1"},dCe={class:"flex-shrink-0 ml-2"},OCe={key:0,xmlns:"http://www.w3.org/2000/svg",width:"16",height:"17",viewBox:"0 0 16 17",fill:"none"},fCe={key:1,xmlns:"http://www.w3.org/2000/svg",width:"16",height:"17",viewBox:"0 0 16 17",fill:"none"},pCe=ve({__name:"ModelVersionRow",props:{version:{},model:{}},setup(e){const t=su(),n=xe(!1);Be(()=>t.reload,(a,o)=>{a!==o&&(n.value=!1)},{deep:!0});const r=(a,o)=>{t.setApplyObject(a,o)},i=()=>{n.value=!0};return(a,o)=>(fe(),qe(Pt,null,[te(D(Xh),{class:"bg-[#3D3D3D] hover:bg-[#4E4E4E] hover:cursor-pointer border-[#F9FAFB]/60 h-12",onClick:i},{default:ce(()=>[te(D(Os),{class:"pl-10 w-[55%] max-w-[200px]"},{default:ce(()=>[$e("div",cCe,[$e("span",uCe,Ot(a.version.version),1),$e("div",dCe,[a.version.public?(fe(),qe("svg",OCe,o[2]||(o[2]=[$e("path",{d:"M1.33325 8.49992C1.33325 8.49992 3.33325 3.83325 7.99992 3.83325C12.6666 3.83325 14.6666 8.49992 14.6666 8.49992C14.6666 8.49992 12.6666 13.1666 7.99992 13.1666C3.33325 13.1666 1.33325 8.49992 1.33325 8.49992Z",stroke:"#9CA3AF","stroke-linecap":"round","stroke-linejoin":"round"},null,-1),$e("path",{d:"M7.99992 10.4999C9.10449 10.4999 9.99992 9.60449 9.99992 8.49992C9.99992 7.39535 9.10449 6.49992 7.99992 6.49992C6.89535 6.49992 5.99992 7.39535 5.99992 8.49992C5.99992 9.60449 6.89535 10.4999 7.99992 10.4999Z",stroke:"#9CA3AF","stroke-linecap":"round","stroke-linejoin":"round"},null,-1)]))):(fe(),qe("svg",fCe,o[3]||(o[3]=[$e("path",{d:"M6.58658 7.08659C6.39009 7.26968 6.23248 7.49048 6.12317 7.73582C6.01386 7.98115 5.95508 8.24598 5.95034 8.51452C5.9456 8.78307 5.995 9.04981 6.09559 9.29884C6.19618 9.54788 6.3459 9.7741 6.53582 9.96402C6.72573 10.1539 6.95196 10.3037 7.20099 10.4042C7.45003 10.5048 7.71677 10.5542 7.98531 10.5495C8.25385 10.5448 8.51869 10.486 8.76402 10.3767C9.00935 10.2674 9.23015 10.1097 9.41325 9.91325M7.15325 3.88659C7.43412 3.85159 7.71687 3.83378 7.99992 3.83325C12.6666 3.83325 14.6666 8.49992 14.6666 8.49992C14.3685 9.138 13.9947 9.73787 13.5533 10.2866M4.40659 4.90659C3.08075 5.80967 2.01983 7.05009 1.33325 8.49992C1.33325 8.49992 3.33325 13.1666 7.99992 13.1666C9.27719 13.17 10.5271 12.7967 11.5933 12.0933M1.33325 1.83325L14.6666 15.1666",stroke:"#9CA3AF","stroke-linecap":"round","stroke-linejoin":"round"},null,-1)])))])])]),_:1}),te(D(Os),{class:"w-[15%]"},{default:ce(()=>[ot(Ot(a.version.base_model),1)]),_:1}),te(D(Os),{class:"w-[15%]"},{default:ce(()=>[ot(Ot(a.version.available?"Available":"Unavailable"),1)]),_:1}),te(D(Os),{class:"w-[15%] flex justify-start"},{default:ce(()=>[te(D(Ur),{variant:"default",onClick:o[0]||(o[0]=Sr(s=>r(a.version,a.model),["stop"])),disabled:!a.version.available,class:xt({"opacity-50":!a.version.available})},{default:ce(()=>o[4]||(o[4]=[ot(" Apply ")])),_:1},8,["disabled","class"])]),_:1})]),_:1}),te(n_,{open:n.value,"onUpdate:open":o[1]||(o[1]=s=>n.value=s),class:"max-w-full h-screen px-6 overflow-hidden pb-6 z-8000",layoutClass:"z-8000",contentClass:"custom-scrollbar max-h-[100vh-120px] overflow-y-auto w-full rounded-tl-lg rounded-tr-lg custom-shadow",title:a.model.name},{default:ce(()=>[te(D(lCe),{modelId:a.model.id,version:a.version},null,8,["modelId","version"])]),_:1},8,["open","title"])],64))}}),hCe={class:"flex items-center justify-center h-full"},mCe={class:"flex items-center space-x-2"},gCe={class:"text-sm"},_Ce={key:0,xmlns:"http://www.w3.org/2000/svg",width:"16",height:"17",viewBox:"0 0 16 17",fill:"none"},bCe={key:1,xmlns:"http://www.w3.org/2000/svg",width:"16",height:"17",viewBox:"0 0 16 17",fill:"none"},yCe={class:"flex justify-end h-full"},vCe={key:1,class:"w-8 h-8"},SCe={class:"w-full flex justify-center mt-8"},ECe=ve({__name:"ModelTable",setup(e){const t=su(),n=xe(new Set),r=xe(""),i=Ie(()=>t.isLoading);Be(()=>t.models,l=>{l.length>0&&(n.value.clear(),n.value.add(l[0].name))},{deep:!0});const a=l=>{n.value.has(l)?n.value.delete(l):n.value.add(l)},o=async(l,c)=>{const{id:u,name:d,versions:O}=c;if(r.value=d,l==="edit"){const f=await y2({id:c.id,source:t.mode});t.setModelDetail(f.data),t.setDialogStatus(!0),r.value=""}if(l==="remove"){if(t.reloadModelSelectList=!1,!await t_({title:"Are you sure you want to delete this model?",desc:"This action cannot be undone.",cancel:"No, Keep It",continue:"Yes, Delete It",z:"z-9000"}))return;if(O&&O.some(h=>h.public)){Ut.warning("Model has public version, cannot remove.");return}s(u)}},s=async l=>{try{await v2(l),Ut.success("Model removed successfully."),t.reloadModelSelectList=!0}catch(c){Ut.error(`Failed to remove model. ${c}`)}};return(l,c)=>(fe(),qe("div",null,[te(D(lke),null,{default:ce(()=>[te(D(uke),null,{default:ce(()=>[te(D(Xh),{class:"hover:bg-transparent border-[#F9FAFB]/60"},{default:ce(()=>[te(D(ky),{class:"w-[55%]"},{default:ce(()=>c[0]||(c[0]=[ot("Name")])),_:1}),te(D(ky),{class:"w-[15%]"},{default:ce(()=>c[1]||(c[1]=[ot("Base Model")])),_:1}),te(D(ky),{class:"w-[15%]"},{default:ce(()=>c[2]||(c[2]=[ot("Status")])),_:1}),te(D(ky),{class:"w-[15%]"},{default:ce(()=>c[3]||(c[3]=[ot("Operate")])),_:1})]),_:1})]),_:1}),te(D(cke),null,{default:ce(()=>[i.value?(fe(),Se(D(Xh),{key:0,class:"bg-transparent hover:bg-transparent"},{default:ce(()=>[te(D(Os),{colspan:"4",class:"h-[400px]"},{default:ce(()=>[$e("div",hCe,[te(D(voe),{class:"h-8 w-8 animate-spin text-[#F9FAFB]"})])]),_:1})]),_:1})):(fe(),qe(Pt,{key:1},[!i.value&&D(t).models.length>0?(fe(!0),qe(Pt,{key:0},Oi(D(t).models,u=>(fe(),qe(Pt,{key:`${u.id}-${u.name}`},[te(D(Xh),{class:"group cursor-pointer border-[#F9FAFB]/60 hover:bg-transparent h-12"},{default:ce(()=>[te(D(Os),{class:"w-[55%]",onClick:d=>a(u.name)},{default:ce(()=>[$e("div",mCe,[$e("span",gCe,[n.value.has(u.name)?(fe(),qe("svg",_Ce,c[4]||(c[4]=[$e("path",{d:"M4 6L8 10L12 6",stroke:"#F9FAFB","stroke-width":"1.5","stroke-linecap":"round","stroke-linejoin":"round"},null,-1)]))):(fe(),qe("svg",bCe,c[5]||(c[5]=[$e("path",{d:"M6 4L10 8L6 12",stroke:"#F9FAFB","stroke-width":"1.5","stroke-linecap":"round","stroke-linejoin":"round"},null,-1)])))]),$e("span",null,Ot(u.name),1),te(D(cQ),{variant:"default"},{default:ce(()=>[ot(Ot(u.type),1)]),_:2},1024)])]),_:2},1032,["onClick"]),te(D(Os),{class:"w-[15%]"},{default:ce(()=>c[6]||(c[6]=[ot("-")])),_:1}),te(D(Os),{class:"w-[15%]"},{default:ce(()=>c[7]||(c[7]=[ot("-")])),_:1}),te(D(Os),{class:"w-[15%]"},{default:ce(()=>[$e("div",yCe,[D(t).mode==="my"||D(t).mode==="my_fork"?(fe(),Se(D(xy),{key:0,class:"bg-[#353535] z-[5100]mmm",open:r.value===u.name,"onUpdate:open":d=>d?r.value=u.name:r.value=""},{default:ce(()=>[te(D(Py),{class:"bg-transparent"},{default:ce(()=>c[8]||(c[8]=[$e("div",{class:"flex justify-center items-center hover:bg-[#222222] rounded-md w-8 h-8"},[$e("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24"},[$e("path",{fill:"white",d:"M12 16a2 2 0 0 1 2 2a2 2 0 0 1-2 2a2 2 0 0 1-2-2a2 2 0 0 1 2-2m0-6a2 2 0 0 1 2 2a2 2 0 0 1-2 2a2 2 0 0 1-2-2a2 2 0 0 1 2-2m0-6a2 2 0 0 1 2 2a2 2 0 0 1-2 2a2 2 0 0 1-2-2a2 2 0 0 1 2-2"})])],-1)])),_:1}),te(D($y),{side:"bottom",align:"end",class:"w-[150px] p-0 bg-[#353535] rounded-lg group-hover:visible z-12000"},{default:ce(()=>[te(D(Ry),null,{default:ce(()=>[te(D(Qy),null,{default:ce(()=>[te(D(Uh),null,{default:ce(()=>[te(D(cl),{value:"edit",onClick:d=>o("edit",u),class:"px-2 py-1.5 mb-1 text-[#F9FAFB] cursor-pointer [&:hover]:!bg-[#6D28D9] [&:hover]:!text-[#F9FAFB]"},{default:ce(()=>c[9]||(c[9]=[ot(" Edit ")])),_:2},1032,["onClick"]),te(D(uQ)),te(D(cl),{value:"remove",onClick:d=>o("remove",u),class:"px-2 py-1.5 mb-1 mt-1 text-[#F9FAFB] cursor-pointer [&:hover]:!bg-[#6D28D9] [&:hover]:!text-[#F9FAFB]"},{default:ce(()=>c[10]||(c[10]=[ot(" Remove ")])),_:2},1032,["onClick"])]),_:2},1024)]),_:2},1024)]),_:2},1024)]),_:2},1024)]),_:2},1032,["open","onUpdate:open"])):(fe(),qe("div",vCe))])]),_:2},1024)]),_:2},1024),n.value.has(u.name)&&u.versions?(fe(!0),qe(Pt,{key:0},Oi(u.versions,d=>(fe(),Se(pCe,{model:u,key:d.version,version:d},null,8,["model","version"]))),128)):kt("",!0)],64))),128)):(fe(),Se(D(Xh),{key:1,class:"hover:bg-transparent"},{default:ce(()=>[te(D(Os),{colspan:"4",class:"h-[400px]"},{default:ce(()=>c[11]||(c[11]=[$e("div",{class:"flex items-center justify-center h-full text-[#F9FAFB]"}," No available data ",-1)])),_:1})]),_:1}))],64))]),_:1})]),_:1}),$e("div",SCe,[i.value?kt("",!0):(fe(),Se(oke,{key:0}))])]))}}),TCe={class:"font-['Inter'] flex flex-col"},wCe={class:"flex flex-col min-h-[650px]"},xCe={class:"flex-1 relative"},$Ce={class:"h-full"},PCe=ve({__name:"Index",props:{modelType:{},selectedBaseModels:{}},emits:["apply"],setup(e,{emit:t}){const n=su(),r=e,i=["my","my_fork","publicity"],a={my:"My Models",my_fork:"My Forks",publicity:"Community Models"},o=async()=>{n.setIsLoading(!0),await ice(n.modelListPathParams,n.filterState).then(p=>{var h,m;p&&p.data?(n.modelListPathParams.total=((h=p==null?void 0:p.data)==null?void 0:h.total)||0,n.models=((m=p==null?void 0:p.data)==null?void 0:m.list)||[]):(n.modelListPathParams.total=0,n.models=[])}).catch(p=>{Ut.error(`Failed to fetch model list. ${p}`),n.modelListPathParams.total=0,n.models=[]}).finally(async()=>{n.setIsLoading(!1)})},s=xe(!1),l=xe(!1),c=async p=>{n.models=[],n.mode=String(p),n.modelListPathParams.mode=n.mode,n.modelListPathParams.current=1,n.mode!=="publicity"&&(n.filterState.sort="Recently"),await o()},u=()=>b2().then(p=>(n.setModelTypes(p!=null&&p.data?p.data:[]),_2())).then(p=>{n.setBaseModelTypes(p!=null&&p.data?p.data:[])}).catch(p=>{Ut.error(`Failed to fetch base model types${p}`),n.setModelTypes([]),n.setBaseModelTypes([])}),d=t;Be(()=>n.applyObject,p=>{p.version&&p.model&&d("apply",p.version,p.model.name)},{deep:!0}),Be(()=>n.closeModelSelectDialog,(p,h)=>{p!==h&&(l.value=!1)},{deep:!0}),Be(()=>n.reload,async(p,h)=>{p!==h&&await o()},{deep:!0}),Be(()=>n.reloadModelSelectList,async(p,h)=>{p!==h&&await o()},{deep:!0}),Be(()=>n.modelListPathParams.current,async(p,h)=>{p!==h&&l.value&&await o()}),ht(async()=>{r.modelType&&(n.selectedModelTypes=r.modelType,n.filterState.model_types=r.modelType),r.selectedBaseModels&&(n.selectedBaseModels=r.selectedBaseModels,n.filterState.base_models=r.selectedBaseModels),await u(),l.value=!0}),Be(()=>l.value,async p=>{p?(r.modelType&&(n.selectedModelTypes=r.modelType,n.filterState.model_types=r.modelType),r.selectedBaseModels&&(n.selectedBaseModels=r.selectedBaseModels,n.filterState.base_models=r.selectedBaseModels),await o()):n.resetModelListPathParams()});const O=async()=>{await o()},f=()=>{l.value=!1};return(p,h)=>(fe(),Se(n_,{open:l.value,"onUpdate:open":h[1]||(h[1]=m=>l.value=m),class:"max-w-[70%] px-6 pb-6 overflow-hidden z-8000",layoutClass:"z-8000",onOnClose:f,contentClass:"custom-scrollbar max-h-[78vh] overflow-y-auto w-full rounded-tl-lg rounded-tr-lg custom-shadow"},{title:ce(()=>h[2]||(h[2]=[$e("span",{class:"text-[#F9FAFB] mb-4 text-[18px] font-semibold leading-[18px] tracking-[-0.45px]"}," Select Model ",-1)])),default:ce(()=>[$e("div",TCe,[te(D(YY),{defaultValue:D(n).mode,class:"h-full flex flex-col","onUpdate:modelValue":c},{default:ce(()=>[te(D(jY),{class:"grid w-full grid-cols-3 h-12 bg-[#4E4E4E] text-white text-sm shrink-0"},{default:ce(()=>[(fe(),qe(Pt,null,Oi(i,m=>te(D(qY),{key:m,value:m,class:"text-sm data-[state=active]:bg-[#9CA3AF] bg-[#4E4E4E] h-10 px-3 py-2 focus:outline-none focus-visible:outline-none"},{default:ce(()=>[ot(Ot(a[m]),1)]),_:2},1032,["value"])),64))]),_:1}),(fe(),qe(Pt,null,Oi(i,m=>(fe(),qe(Pt,{key:m},[D(n).mode===m?(fe(),Se(D(VQe),{key:0,value:m,class:"flex-1 flex flex-col overflow-hidden"},{default:ce(()=>[$e("div",wCe,[$e("div",xCe,[te(JQe,{"show-sort-popover":s.value,"onUpdate:showSortPopover":h[0]||(h[0]=g=>s.value=g),onFetchData:O,class:"shrink-0"},null,8,["show-sort-popover"]),$e("div",$Ce,[te(ECe)])]),h[3]||(h[3]=$e("div",{class:"h-4"},null,-1))])]),_:2},1032,["value"])):kt("",!0)],64))),64))]),_:1},8,["defaultValue"])])]),_:1},8,["open"]))}}),RCe=e=>{let t=!1;const n=`bizyair-model-select-${Date.now()}-${Math.random().toString(36).substr(2,9)}`,r=document.createElement("div");r.id=n,document.body.appendChild(r);const i=jf(PCe,{...e,onClose:()=>{t&&(i.unmount(),t=!1),document.body.contains(r)&&document.body.removeChild(r)},onApply:(...o)=>{e!=null&&e.onApply&&(e.onApply(...o),t&&(i.unmount(),t=!1),document.body.contains(r)&&document.body.removeChild(r))}});i.directive("debounce",{mounted(o,s){let l=null;o.addEventListener("keyup",()=>{l&&clearTimeout(l),l=setTimeout(()=>{s.value()},s.arg||500)})},unmounted(o,s){s&&o.removeEventListener("keyup",s.value)}});const a=i.mount(r);return t=!0,{instance:a}};let zh=jf(WQe);zh.use(lse());function QCe(e,t){zh.provide("comfyUIApp",t),zh.mount(e)}function kCe(){zh&&zh.unmount()}const CCe=36,ZY=1,ACe=2,WO=3,dQ=4,ICe=5,DCe=6,NCe=7,MCe=8,LCe=9,UCe=10,XCe=11,zCe=12,BCe=13,FCe=14,WCe=15,VCe=16,YCe=17,HY=18,jCe=19,KY=20,JY=21,ej=22,qCe=23,GCe=24;function OQ(e){return e>=65&&e<=90||e>=97&&e<=122||e>=48&&e<=57}function ZCe(e){return e>=48&&e<=57||e>=97&&e<=102||e>=65&&e<=70}function Mu(e,t,n){for(let r=!1;;){if(e.next<0)return;if(e.next==t&&!r){e.advance();return}r=n&&!r&&e.next==92,e.advance()}}function HCe(e,t){e:for(;;){if(e.next<0)return;if(e.next==36){e.advance();for(let n=0;n)".charCodeAt(n);for(;;){if(e.next<0)return;if(e.next==r&&e.peek(1)==39){e.advance(2);return}e.advance()}}function fQ(e,t){for(;!(e.next!=95&&!OQ(e.next));)t!=null&&(t+=String.fromCharCode(e.next)),e.advance();return t}function JCe(e){if(e.next==39||e.next==34||e.next==96){let t=e.next;e.advance(),Mu(e,t,!1)}else fQ(e)}function tj(e,t){for(;e.next==48||e.next==49;)e.advance();t&&e.next==t&&e.advance()}function nj(e,t){for(;;){if(e.next==46){if(t)break;t=!0}else if(e.next<48||e.next>57)break;e.advance()}if(e.next==69||e.next==101)for(e.advance(),(e.next==43||e.next==45)&&e.advance();e.next>=48&&e.next<=57;)e.advance()}function rj(e){for(;!(e.next<0||e.next==10);)e.advance()}function Lu(e,t){for(let n=0;n!=&|~^/",specialVar:"?",identifierQuotes:'"',caseInsensitiveIdentifiers:!1,words:ij(Xu,Uu)};function eAe(e,t,n,r){let i={};for(let a in hQ)i[a]=(e.hasOwnProperty(a)?e:hQ)[a];return t&&(i.words=ij(t,n||"",r)),i}function aj(e){return new $t(t=>{var n;let{next:r}=t;if(t.advance(),Lu(r,pQ)){for(;Lu(t.next,pQ);)t.advance();t.acceptToken(CCe)}else if(r==36&&e.doubleDollarQuotedStrings){let i=fQ(t,"");t.next==36&&(t.advance(),HCe(t,i),t.acceptToken(WO))}else if(r==39||r==34&&e.doubleQuotedStrings)Mu(t,r,e.backslashEscapes),t.acceptToken(WO);else if(r==35&&e.hashComments||r==47&&t.next==47&&e.slashComments)rj(t),t.acceptToken(ZY);else if(r==45&&t.next==45&&(!e.spaceAfterDashes||t.peek(1)==32))rj(t),t.acceptToken(ZY);else if(r==47&&t.next==42){t.advance();for(let i=1;;){let a=t.next;if(t.next<0)break;if(t.advance(),a==42&&t.next==47){if(i--,t.advance(),!i)break}else a==47&&t.next==42&&(i++,t.advance())}t.acceptToken(ACe)}else if((r==101||r==69)&&t.next==39)t.advance(),Mu(t,39,!0),t.acceptToken(WO);else if((r==110||r==78)&&t.next==39&&e.charSetCasts)t.advance(),Mu(t,39,e.backslashEscapes),t.acceptToken(WO);else if(r==95&&e.charSetCasts)for(let i=0;;i++){if(t.next==39&&i>1){t.advance(),Mu(t,39,e.backslashEscapes),t.acceptToken(WO);break}if(!OQ(t.next))break;t.advance()}else if(e.plsqlQuotingMechanism&&(r==113||r==81)&&t.next==39&&t.peek(1)>0&&!Lu(t.peek(1),pQ)){let i=t.peek(1);t.advance(2),KCe(t,i),t.acceptToken(WO)}else if(r==40)t.acceptToken(NCe);else if(r==41)t.acceptToken(MCe);else if(r==123)t.acceptToken(LCe);else if(r==125)t.acceptToken(UCe);else if(r==91)t.acceptToken(XCe);else if(r==93)t.acceptToken(zCe);else if(r==59)t.acceptToken(BCe);else if(e.unquotedBitLiterals&&r==48&&t.next==98)t.advance(),tj(t),t.acceptToken(ej);else if((r==98||r==66)&&(t.next==39||t.next==34)){const i=t.next;t.advance(),e.treatBitsAsBytes?(Mu(t,i,e.backslashEscapes),t.acceptToken(qCe)):(tj(t,i),t.acceptToken(ej))}else if(r==48&&(t.next==120||t.next==88)||(r==120||r==88)&&t.next==39){let i=t.next==39;for(t.advance();ZCe(t.next);)t.advance();i&&t.next==39&&t.advance(),t.acceptToken(dQ)}else if(r==46&&t.next>=48&&t.next<=57)nj(t,!0),t.acceptToken(dQ);else if(r==46)t.acceptToken(FCe);else if(r>=48&&r<=57)nj(t,!1),t.acceptToken(dQ);else if(Lu(r,e.operatorChars)){for(;Lu(t.next,e.operatorChars);)t.advance();t.acceptToken(WCe)}else if(Lu(r,e.specialVar))t.next==r&&t.advance(),JCe(t),t.acceptToken(YCe);else if(Lu(r,e.identifierQuotes))Mu(t,r,!1),t.acceptToken(jCe);else if(r==58||r==44)t.acceptToken(VCe);else if(OQ(r)){let i=fQ(t,String.fromCharCode(r));t.acceptToken(t.next==46||t.peek(-i.length-1)==46?HY:(n=e.words[i.toLowerCase()])!==null&&n!==void 0?n:HY)}})}const oj=aj(hQ),tAe=jn.deserialize({version:14,states:"%vQ]QQOOO#wQRO'#DSO$OQQO'#CwO%eQQO'#CxO%lQQO'#CyO%sQQO'#CzOOQQ'#DS'#DSOOQQ'#C}'#C}O'UQRO'#C{OOQQ'#Cv'#CvOOQQ'#C|'#C|Q]QQOOQOQQOOO'`QQO'#DOO(xQRO,59cO)PQQO,59cO)UQQO'#DSOOQQ,59d,59dO)cQQO,59dOOQQ,59e,59eO)jQQO,59eOOQQ,59f,59fO)qQQO,59fOOQQ-E6{-E6{OOQQ,59b,59bOOQQ-E6z-E6zOOQQ,59j,59jOOQQ-E6|-E6|O+VQRO1G.}O+^QQO,59cOOQQ1G/O1G/OOOQQ1G/P1G/POOQQ1G/Q1G/QP+kQQO'#C}O+rQQO1G.}O)PQQO,59cO,PQQO'#Cw",stateData:",[~OtOSPOSQOS~ORUOSUOTUOUUOVROXSOZTO]XO^QO_UO`UOaPObPOcPOdUOeUOfUOgUOhUO~O^]ORvXSvXTvXUvXVvXXvXZvX]vX_vX`vXavXbvXcvXdvXevXfvXgvXhvX~OsvX~P!jOa_Ob_Oc_O~ORUOSUOTUOUUOVROXSOZTO^tO_UO`UOa`Ob`Oc`OdUOeUOfUOgUOhUO~OWaO~P$ZOYcO~P$ZO[eO~P$ZORUOSUOTUOUUOVROXSOZTO^QO_UO`UOaPObPOcPOdUOeUOfUOgUOhUO~O]hOsoX~P%zOajObjOcjO~O^]ORkaSkaTkaUkaVkaXkaZka]ka_ka`kaakabkackadkaekafkagkahka~Oska~P'kO^]O~OWvXYvX[vX~P!jOWnO~P$ZOYoO~P$ZO[pO~P$ZO^]ORkiSkiTkiUkiVkiXkiZki]ki_ki`kiakibkickidkiekifkigkihki~Oski~P)xOWkaYka[ka~P'kO]hO~P$ZOWkiYki[ki~P)xOasObsOcsO~O",goto:"#hwPPPPPPPPPPPPPPPPPPPPPPPPPPx||||!Y!^!d!xPPP#[TYOZeUORSTWZbdfqT[OZQZORiZSWOZQbRQdSQfTZgWbdfqQ^PWk^lmrQl_Qm`RrseVORSTWZbdfq",nodeNames:"⚠ LineComment BlockComment String Number Bool Null ( ) { } [ ] ; . Operator Punctuation SpecialVar Identifier QuotedIdentifier Keyword Type Bits Bytes Builtin Script Statement CompositeIdentifier Parens Braces Brackets Statement",maxTerm:38,nodeProps:[["isolate",-4,1,2,3,19,""]],skippedNodes:[0,1,2],repeatNodeCount:3,tokenData:"RORO",tokenizers:[0,oj],topRules:{Script:[0,25]},tokenPrec:0});function mQ(e){let t=e.cursor().moveTo(e.from,-1);for(;/Comment/.test(t.name);)t.moveTo(t.from,-1);return t.node}function Bh(e,t){let n=e.sliceString(t.from,t.to),r=/^([`'"])(.*)\1$/.exec(n);return r?r[2]:n}function Cy(e){return e&&(e.name=="Identifier"||e.name=="QuotedIdentifier")}function nAe(e,t){if(t.name=="CompositeIdentifier"){let n=[];for(let r=t.firstChild;r;r=r.nextSibling)Cy(r)&&n.push(Bh(e,r));return n}return[Bh(e,t)]}function sj(e,t){for(let n=[];;){if(!t||t.name!=".")return n;let r=mQ(t);if(!Cy(r))return n;n.unshift(Bh(e,r)),t=mQ(r)}}function rAe(e,t){let n=_n(e).resolveInner(t,-1),r=aAe(e.doc,n);return n.name=="Identifier"||n.name=="QuotedIdentifier"||n.name=="Keyword"?{from:n.from,quoted:n.name=="QuotedIdentifier"?e.doc.sliceString(n.from,n.from+1):null,parents:sj(e.doc,mQ(n)),aliases:r}:n.name=="."?{from:t,quoted:null,parents:sj(e.doc,n),aliases:r}:{from:t,quoted:null,parents:[],empty:!0,aliases:r}}const iAe=new Set("where group having order union intersect except all distinct limit offset fetch for".split(" "));function aAe(e,t){let n;for(let i=t;!n;i=i.parent){if(!i)return null;i.name=="Statement"&&(n=i)}let r=null;for(let i=n.firstChild,a=!1,o=null;i;i=i.nextSibling){let s=i.name=="Keyword"?e.sliceString(i.from,i.to).toLowerCase():null,l=null;if(!a)a=s=="from";else if(s=="as"&&o&&Cy(i.nextSibling))l=Bh(e,i.nextSibling);else{if(s&&iAe.has(s))break;o&&Cy(i)&&(l=Bh(e,i))}l&&(r||(r=Object.create(null)),r[l]=nAe(e,o)),o=/Identifier$/.test(i.name)?i:null}return r}function oAe(e,t){return e?t.map(n=>Object.assign(Object.assign({},n),{label:n.label[0]==e?n.label:e+n.label+e,apply:void 0})):t}const sAe=/^\w*$/,lAe=/^[`'"]?\w*[`'"]?$/;function lj(e){return e.self&&typeof e.self.label=="string"}class gQ{constructor(t,n){this.idQuote=t,this.idCaseInsensitive=n,this.list=[],this.children=void 0}child(t){let n=this.children||(this.children=Object.create(null)),r=n[t];return r||(t&&!this.list.some(i=>i.label==t)&&this.list.push(cj(t,"type",this.idQuote,this.idCaseInsensitive)),n[t]=new gQ(this.idQuote,this.idCaseInsensitive))}maybeChild(t){return this.children?this.children[t]:null}addCompletion(t){let n=this.list.findIndex(r=>r.label==t.label);n>-1?this.list[n]=t:this.list.push(t)}addCompletions(t){for(let n of t)this.addCompletion(typeof n=="string"?cj(n,"property",this.idQuote,this.idCaseInsensitive):n)}addNamespace(t){Array.isArray(t)?this.addCompletions(t):lj(t)?this.addNamespace(t.children):this.addNamespaceObject(t)}addNamespaceObject(t){for(let n of Object.keys(t)){let r=t[n],i=null,a=n.replace(/\\?\./g,s=>s=="."?"\0":s).split("\0"),o=this;lj(r)&&(i=r.self,r=r.children);for(let s=0;s{let{parents:d,from:O,quoted:f,empty:p,aliases:h}=rAe(u.state,u.pos);if(p&&!u.explicit)return null;h&&d.length==1&&(d=h[d[0]]||d);let m=l;for(let b of d){for(;!m.children||!m.children[b];)if(m==l&&c)m=c;else if(m==c&&r)m=m.child(r);else return null;let y=m.maybeChild(b);if(!y)return null;m=y}let g=f&&u.state.sliceDoc(u.pos,u.pos+1)==f,_=m.list;return m==l&&h&&(_=_.concat(Object.keys(h).map(b=>({label:b,type:"constant"})))),{from:O,to:g?u.pos+1:void 0,options:oAe(f,_),validFor:f?lAe:sAe}}}function uAe(e){return e==JY?"type":e==KY?"keyword":"variable"}function dAe(e,t,n){let r=Object.keys(e).map(i=>n(t?i.toUpperCase():i,uAe(e[i])));return ey(["QuotedIdentifier","SpecialVar","String","LineComment","BlockComment","."],bh(r))}let OAe=tAe.configure({props:[lr.add({Statement:Gn()}),cr.add({Statement(e,t){return{from:Math.min(e.from+100,t.doc.lineAt(e.from).to),to:e.to}},BlockComment(e){return{from:e.from+2,to:e.to-2}}}),Vn({Keyword:U.keyword,Type:U.typeName,Builtin:U.standard(U.name),Bits:U.number,Bytes:U.string,Bool:U.bool,Null:U.null,Number:U.number,String:U.string,Identifier:U.name,QuotedIdentifier:U.special(U.string),SpecialVar:U.special(U.name),LineComment:U.lineComment,BlockComment:U.blockComment,Operator:U.operator,"Semi Punctuation":U.punctuation,"( )":U.paren,"{ }":U.brace,"[ ]":U.squareBracket})]});class ho{constructor(t,n,r){this.dialect=t,this.language=n,this.spec=r}get extension(){return this.language.extension}static define(t){let n=eAe(t,t.keywords,t.types,t.builtin),r=Yn.define({name:"sql",parser:OAe.configure({tokenizers:[{from:oj,to:aj(n)}]}),languageData:{commentTokens:{line:"--",block:{open:"/*",close:"*/"}},closeBrackets:{brackets:["(","[","{","'",'"',"`"]}}});return new ho(n,r,t)}}function fAe(e,t){return{label:e,type:t,boost:-1}}function uj(e,t=!1,n){return dAe(e.dialect.words,t,n||fAe)}function dj(e){return e.schema?cAe(e.schema,e.tables,e.schemas,e.defaultTable,e.defaultSchema,e.dialect||Ay):()=>null}function pAe(e){return e.schema?(e.dialect||Ay).language.data.of({autocomplete:dj(e)}):[]}function hAe(e={}){let t=e.dialect||Ay;return new Nn(t.language,[pAe(e),t.language.data.of({autocomplete:uj(t,e.upperCaseKeywords,e.keywordCompletion)})])}const Ay=ho.define({}),mAe=ho.define({charSetCasts:!0,doubleDollarQuotedStrings:!0,operatorChars:"+-*/<>=~!@#%^&|`?",specialVar:"",keywords:Xu+"abort abs absent access according ada admin aggregate alias also always analyse analyze array_agg array_max_cardinality asensitive assert assignment asymmetric atomic attach attribute attributes avg backward base64 begin_frame begin_partition bernoulli bit_length blocked bom cache called cardinality catalog_name ceil ceiling chain char_length character_length character_set_catalog character_set_name character_set_schema characteristics characters checkpoint class class_origin cluster coalesce cobol collation_catalog collation_name collation_schema collect column_name columns command_function command_function_code comment comments committed concurrently condition_number configuration conflict connection_name constant constraint_catalog constraint_name constraint_schema contains content control conversion convert copy corr cost covar_pop covar_samp csv cume_dist current_catalog current_row current_schema cursor_name database datalink datatype datetime_interval_code datetime_interval_precision db debug defaults defined definer degree delimiter delimiters dense_rank depends derived detach detail dictionary disable discard dispatch dlnewcopy dlpreviouscopy dlurlcomplete dlurlcompleteonly dlurlcompletewrite dlurlpath dlurlpathonly dlurlpathwrite dlurlscheme dlurlserver dlvalue document dump dynamic_function dynamic_function_code element elsif empty enable encoding encrypted end_frame end_partition endexec enforced enum errcode error event every exclude excluding exclusive exp explain expression extension extract family file filter final first_value flag floor following force foreach fortran forward frame_row freeze fs functions fusion generated granted greatest groups handler header hex hierarchy hint id ignore ilike immediately immutable implementation implicit import include including increment indent index indexes info inherit inherits inline insensitive instance instantiable instead integrity intersection invoker isnull key_member key_type label lag last_value lead leakproof least length library like_regex link listen ln load location lock locked log logged lower mapping matched materialized max max_cardinality maxvalue member merge message message_length message_octet_length message_text min minvalue mod mode more move multiset mumps name namespace nfc nfd nfkc nfkd nil normalize normalized nothing notice notify notnull nowait nth_value ntile nullable nullif nulls number occurrences_regex octet_length octets off offset oids operator options ordering others over overlay overriding owned owner parallel parameter_mode parameter_name parameter_ordinal_position parameter_specific_catalog parameter_specific_name parameter_specific_schema parser partition pascal passing passthrough password percent percent_rank percentile_cont percentile_disc perform period permission pg_context pg_datatype_name pg_exception_context pg_exception_detail pg_exception_hint placing plans pli policy portion position position_regex power precedes preceding prepared print_strict_params procedural procedures program publication query quote raise range rank reassign recheck recovery refresh regr_avgx regr_avgy regr_count regr_intercept regr_r2 regr_slope regr_sxx regr_sxy regr_syy reindex rename repeatable replace replica requiring reset respect restart restore result_oid returned_cardinality returned_length returned_octet_length returned_sqlstate returning reverse routine_catalog routine_name routine_schema routines row_count row_number rowtype rule scale schema_name schemas scope scope_catalog scope_name scope_schema security selective self sensitive sequence sequences serializable server server_name setof share show simple skip slice snapshot source specific_name sqlcode sqlerror sqrt stable stacked standalone statement statistics stddev_pop stddev_samp stdin stdout storage strict strip structure style subclass_origin submultiset subscription substring substring_regex succeeds sum symmetric sysid system system_time table_name tables tablesample tablespace temp template ties token top_level_count transaction_active transactions_committed transactions_rolled_back transform transforms translate translate_regex trigger_catalog trigger_name trigger_schema trim trim_array truncate trusted type types uescape unbounded uncommitted unencrypted unlink unlisten unlogged unnamed untyped upper uri use_column use_variable user_defined_type_catalog user_defined_type_code user_defined_type_name user_defined_type_schema vacuum valid validate validator value_of var_pop var_samp varbinary variable_conflict variadic verbose version versioning views volatile warning whitespace width_bucket window within wrapper xmlagg xmlattributes xmlbinary xmlcast xmlcomment xmlconcat xmldeclaration xmldocument xmlelement xmlexists xmlforest xmliterate xmlnamespaces xmlparse xmlpi xmlquery xmlroot xmlschema xmlserialize xmltable xmltext xmlvalidate yes",types:Uu+"bigint int8 bigserial serial8 varbit bool box bytea cidr circle precision float8 inet int4 json jsonb line lseg macaddr macaddr8 money numeric pg_lsn point polygon float4 int2 smallserial serial2 serial serial4 text timetz timestamptz tsquery tsvector txid_snapshot uuid xml"}),Oj="accessible algorithm analyze asensitive authors auto_increment autocommit avg avg_row_length binlog btree cache catalog_name chain change changed checkpoint checksum class_origin client_statistics coalesce code collations columns comment committed completion concurrent consistent contains contributors convert database databases day_hour day_microsecond day_minute day_second delay_key_write delayed delimiter des_key_file dev_pop dev_samp deviance directory disable discard distinctrow div dual dumpfile enable enclosed ends engine engines enum errors escaped even event events every explain extended fast field fields flush force found_rows fulltext grants handler hash high_priority hosts hour_microsecond hour_minute hour_second ignore ignore_server_ids import index index_statistics infile innodb insensitive insert_method install invoker iterate keys kill linear lines list load lock logs low_priority master master_heartbeat_period master_ssl_verify_server_cert masters max max_rows maxvalue message_text middleint migrate min min_rows minute_microsecond minute_second mod mode modify mutex mysql_errno no_write_to_binlog offline offset one online optimize optionally outfile pack_keys parser partition partitions password phase plugin plugins prev processlist profile profiles purge query quick range read_write rebuild recover regexp relaylog remove rename reorganize repair repeatable replace require resume rlike row_format rtree schedule schema_name schemas second_microsecond security sensitive separator serializable server share show slave slow snapshot soname spatial sql_big_result sql_buffer_result sql_cache sql_calc_found_rows sql_no_cache sql_small_result ssl starting starts std stddev stddev_pop stddev_samp storage straight_join subclass_origin sum suspend table_name table_statistics tables tablespace terminated triggers truncate uncommitted uninstall unlock upgrade use use_frm user_resources user_statistics utc_date utc_time utc_timestamp variables views warnings xa xor year_month zerofill",fj=Uu+"bool blob long longblob longtext medium mediumblob mediumint mediumtext tinyblob tinyint tinytext text bigint int1 int2 int3 int4 int8 float4 float8 varbinary varcharacter precision datetime unsigned signed",pj="charset clear edit ego help nopager notee nowarning pager print prompt quit rehash source status system tee",gAe=ho.define({operatorChars:"*+-%<>!=&|^",charSetCasts:!0,doubleQuotedStrings:!0,unquotedBitLiterals:!0,hashComments:!0,spaceAfterDashes:!0,specialVar:"@?",identifierQuotes:"`",keywords:Xu+"group_concat "+Oj,types:fj,builtin:pj}),_Ae=ho.define({operatorChars:"*+-%<>!=&|^",charSetCasts:!0,doubleQuotedStrings:!0,unquotedBitLiterals:!0,hashComments:!0,spaceAfterDashes:!0,specialVar:"@?",identifierQuotes:"`",keywords:Xu+"always generated groupby_concat hard persistent shutdown soft virtual "+Oj,types:fj,builtin:pj}),bAe=ho.define({keywords:Xu+"trigger proc view index for add constraint key primary foreign collate clustered nonclustered declare exec go if use index holdlock nolock nowait paglock pivot readcommitted readcommittedlock readpast readuncommitted repeatableread rowlock serializable snapshot tablock tablockx unpivot updlock with",types:Uu+"bigint smallint smallmoney tinyint money real text nvarchar ntext varbinary image hierarchyid uniqueidentifier sql_variant xml",builtin:"binary_checksum checksum connectionproperty context_info current_request_id error_line error_message error_number error_procedure error_severity error_state formatmessage get_filestream_transaction_context getansinull host_id host_name isnull isnumeric min_active_rowversion newid newsequentialid rowcount_big xact_state object_id",operatorChars:"*+-%<>!=^&|/",specialVar:"@"}),yAe=ho.define({keywords:Xu+"abort analyze attach autoincrement conflict database detach exclusive fail glob ignore index indexed instead isnull notnull offset plan pragma query raise regexp reindex rename replace temp vacuum virtual",types:Uu+"bool blob long longblob longtext medium mediumblob mediumint mediumtext tinyblob tinyint tinytext text bigint int2 int8 unsigned signed real",builtin:"auth backup bail changes clone databases dbinfo dump echo eqp explain fullschema headers help import imposter indexes iotrace lint load log mode nullvalue once print prompt quit restore save scanstats separator shell show stats system tables testcase timeout timer trace vfsinfo vfslist vfsname width",operatorChars:"*+-%<>!=&|/~",identifierQuotes:'`"',specialVar:"@:?$"}),vAe=ho.define({keywords:"add all allow alter and any apply as asc authorize batch begin by clustering columnfamily compact consistency count create custom delete desc distinct drop each_quorum exists filtering from grant if in index insert into key keyspace keyspaces level limit local_one local_quorum modify nan norecursive nosuperuser not of on one order password permission permissions primary quorum rename revoke schema select set storage superuser table three to token truncate ttl two type unlogged update use user users using values where with writetime infinity NaN",types:Uu+"ascii bigint blob counter frozen inet list map static text timeuuid tuple uuid varint",slashComments:!0}),SAe=ho.define({keywords:Xu+"abort accept access add all alter and any arraylen as asc assert assign at attributes audit authorization avg base_table begin between binary_integer body by case cast char_base check close cluster clusters colauth column comment commit compress connected constant constraint crash create current currval cursor data_base database dba deallocate debugoff debugon declare default definition delay delete desc digits dispose distinct do drop else elseif elsif enable end entry exception exception_init exchange exclusive exists external fast fetch file for force form from function generic goto grant group having identified if immediate in increment index indexes indicator initial initrans insert interface intersect into is key level library like limited local lock log logging loop master maxextents maxtrans member minextents minus mislabel mode modify multiset new next no noaudit nocompress nologging noparallel not nowait number_base of off offline on online only option or order out package parallel partition pctfree pctincrease pctused pls_integer positive positiven pragma primary prior private privileges procedure public raise range raw rebuild record ref references refresh rename replace resource restrict return returning returns reverse revoke rollback row rowid rowlabel rownum rows run savepoint schema segment select separate set share snapshot some space split sql start statement storage subtype successful synonym tabauth table tables tablespace task terminate then to trigger truncate type union unique unlimited unrecoverable unusable update use using validate value values variable view views when whenever where while with work",builtin:"appinfo arraysize autocommit autoprint autorecovery autotrace blockterminator break btitle cmdsep colsep compatibility compute concat copycommit copytypecheck define echo editfile embedded feedback flagger flush heading headsep instance linesize lno loboffset logsource longchunksize markup native newpage numformat numwidth pagesize pause pno recsep recsepchar repfooter repheader serveroutput shiftinout show showmode spool sqlblanklines sqlcase sqlcode sqlcontinue sqlnumber sqlpluscompatibility sqlprefix sqlprompt sqlterminator suffix tab term termout timing trimout trimspool ttitle underline verify version wrap",types:Uu+"ascii bfile bfilename bigserial bit blob dec long number nvarchar nvarchar2 serial smallint string text uid varchar2 xml",operatorChars:"*/+-%<>!=~",doubleQuotedStrings:!0,charSetCasts:!0,plsqlQuotingMechanism:!0}),EAe=Object.freeze(Object.defineProperty({__proto__:null,Cassandra:vAe,MSSQL:bAe,MariaSQL:_Ae,MySQL:gAe,PLSQL:SAe,PostgreSQL:mAe,SQLDialect:ho,SQLite:yAe,StandardSQL:Ay,keywordCompletionSource:uj,schemaCompletionSource:dj,sql:hAe},Symbol.toStringTag,{value:"Module"})),hj=1,TAe=2,wAe=3,xAe=82,$Ae=76,PAe=117,RAe=85,QAe=97,kAe=122,CAe=65,AAe=90,IAe=95,_Q=48,mj=34,DAe=40,gj=41,NAe=32,_j=62,MAe=new $t(e=>{if(e.next==$Ae||e.next==RAe?e.advance():e.next==PAe&&(e.advance(),e.next==_Q+8&&e.advance()),e.next!=xAe||(e.advance(),e.next!=mj))return;e.advance();let t="";for(;e.next!=DAe;){if(e.next==NAe||e.next<=13||e.next==gj)return;t+=String.fromCharCode(e.next),e.advance()}for(e.advance();;){if(e.next<0)return e.acceptToken(hj);if(e.next==gj){let n=!0;for(let r=0;n&&r{if(e.next==_j)e.peek(1)==_j&&e.acceptToken(TAe,1);else{let t=!1,n=0;for(;;n++){if(e.next>=CAe&&e.next<=AAe)t=!0;else{if(e.next>=QAe&&e.next<=kAe)return;if(e.next!=IAe&&!(e.next>=_Q&&e.next<=_Q+9))break}e.advance()}t&&n>1&&e.acceptToken(wAe)}},{extend:!0}),UAe=Vn({"typedef struct union enum class typename decltype auto template operator friend noexcept namespace using requires concept import export module __attribute__ __declspec __based":U.definitionKeyword,"extern MsCallModifier MsPointerModifier extern static register thread_local inline const volatile restrict _Atomic mutable constexpr constinit consteval virtual explicit VirtualSpecifier Access":U.modifier,"if else switch for while do case default return break continue goto throw try catch":U.controlKeyword,"co_return co_yield co_await":U.controlKeyword,"new sizeof delete static_assert":U.operatorKeyword,"NULL nullptr":U.null,this:U.self,"True False":U.bool,"TypeSize PrimitiveType":U.standard(U.typeName),TypeIdentifier:U.typeName,FieldIdentifier:U.propertyName,"CallExpression/FieldExpression/FieldIdentifier":U.function(U.propertyName),"ModuleName/Identifier":U.namespace,PartitionName:U.labelName,StatementIdentifier:U.labelName,"Identifier DestructorName":U.variableName,"CallExpression/Identifier":U.function(U.variableName),"CallExpression/ScopedIdentifier/Identifier":U.function(U.variableName),"FunctionDeclarator/Identifier FunctionDeclarator/DestructorName":U.function(U.definition(U.variableName)),NamespaceIdentifier:U.namespace,OperatorName:U.operator,ArithOp:U.arithmeticOperator,LogicOp:U.logicOperator,BitOp:U.bitwiseOperator,CompareOp:U.compareOperator,AssignOp:U.definitionOperator,UpdateOp:U.updateOperator,LineComment:U.lineComment,BlockComment:U.blockComment,Number:U.number,String:U.string,"RawString SystemLibString":U.special(U.string),CharLiteral:U.character,EscapeSequence:U.escape,"UserDefinedLiteral/Identifier":U.literal,PreProcArg:U.meta,"PreprocDirectiveName #include #ifdef #ifndef #if #define #else #endif #elif":U.processingInstruction,MacroName:U.special(U.name),"( )":U.paren,"[ ]":U.squareBracket,"{ }":U.brace,"< >":U.angleBracket,". ->":U.derefOperator,", ;":U.separator}),XAe={__proto__:null,bool:34,char:34,int:34,float:34,double:34,void:34,size_t:34,ssize_t:34,intptr_t:34,uintptr_t:34,charptr_t:34,int8_t:34,int16_t:34,int32_t:34,int64_t:34,uint8_t:34,uint16_t:34,uint32_t:34,uint64_t:34,char8_t:34,char16_t:34,char32_t:34,char64_t:34,const:68,volatile:70,restrict:72,_Atomic:74,mutable:76,constexpr:78,constinit:80,consteval:82,struct:86,__declspec:90,final:148,override:148,public:152,private:152,protected:152,virtual:154,extern:160,static:162,register:164,inline:166,thread_local:168,__attribute__:172,__based:178,__restrict:180,__uptr:180,__sptr:180,_unaligned:180,__unaligned:180,noexcept:194,requires:198,TRUE:784,true:784,FALSE:786,false:786,typename:218,class:220,template:234,throw:248,__cdecl:256,__clrcall:256,__stdcall:256,__fastcall:256,__thiscall:256,__vectorcall:256,try:260,catch:264,export:282,import:286,case:296,default:298,if:308,else:314,switch:318,do:322,while:324,for:330,return:334,break:338,continue:342,goto:346,co_return:350,co_yield:354,using:362,typedef:366,namespace:380,new:398,delete:400,co_await:402,concept:406,enum:410,static_assert:414,friend:422,union:424,explicit:430,operator:444,module:456,signed:518,unsigned:518,long:518,short:518,decltype:528,auto:530,sizeof:566,NULL:572,nullptr:586,this:588},zAe={__proto__:null,"<":131},BAe={__proto__:null,">":135},FAe={__proto__:null,operator:388,new:576,delete:582},WAe=jn.deserialize({version:14,states:"$:|Q!QQVOOP'gOUOOO(XOWO'#CdO,RQUO'#CgO,]QUO'#FjO-sQbO'#CwO.UQUO'#CwO0TQUO'#KZO0[QUO'#CvO0gOpO'#DvO0oQ!dO'#D]OOQR'#JO'#JOO5XQVO'#GUO5fQUO'#JVOOQQ'#JV'#JVO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%.d%.jPPP%.t%/P%/S%/Y%0a%0d%0n%0x%0|%2Q%2s%2y#@uP%3d%3t%3w%4X%4e%4i%4o%4u$'y$'|$'|%4x%4{P%5V%5YR#cP'`mO[aefwx{!W!X!g!k!n!r!s!v!x#X#Y#[#g#i#l#q#r#s#t#u#v#w#x#y#z#{#}$U$W$Y$e$f$k%]%m&Q&S&W&b&f&x&y&|'O'P'b'i'j'y(`(b(i)l)r*h*i*l*q*r*v+W+Y+h+j+k,P,R,n,q,w-]-^-a-g.P.Q.U.}/Q/[/c/l/n/s/u0h0{1Q1a1b1l1p1z1|2c2f2i2u2z2}3i4O4R4W4a5Y5e5q6_6c6f6h6j6t6v6{7b7j7m8e8g8m8s8t9R9V9]9_9l9o9p9{:O:U:W:]:b:fU%om%p7QQ&m!`Q(j#]d0P)}/|/}0O0R4}5O5P5S8QR7Q3Tb}Oaewx{!g&S*q&v$i[!W!X!k!n!r!s!v!x#X#Y#[#g#i#l#q#r#s#t#u#v#w#x#y#z#{#}$U$W$Y$e$f$k%]%m&Q&W&b&f&x&y&|'O'P'b'i'j'y(`(b(i)l)r*h*i*l*r*v+W+Y+h+j+k,P,R,n,q,w-]-^-a-g.P.Q.U.}/Q/[/c/l/n/s/u0{1a1b1l1p1z1|2c2f2i2u2z2}3i4O4R4W4a5Y5e5q6_6c6f6h6j6t6v6{7b7j7m8e8g8m8s8t9R9V9]9_9l9o9p9{:O:U:W:]:b:fS%`f0h#d%jgnp|#O$g$|$}%S%d%h%i%w&s't'u(Q*Y*`*b*t+],l,v-_-p-w.f.m.o0]0y0z1O1S2_2j5a6g;W;X;Y;`;a;b;o;p;q;r;v;w;x;y MacroName LineComment BlockComment PreprocDirective #include String EscapeSequence SystemLibString Identifier ArgumentList ( ConditionalExpression AssignmentExpression CallExpression PrimitiveType FieldExpression FieldIdentifier DestructorName TemplateMethod ScopedFieldIdentifier NamespaceIdentifier TemplateType TypeIdentifier ScopedTypeIdentifier ScopedNamespaceIdentifier :: NamespaceIdentifier TypeIdentifier TemplateArgumentList < TypeDescriptor const volatile restrict _Atomic mutable constexpr constinit consteval StructSpecifier struct MsDeclspecModifier __declspec ) Attribute AttributeName Identifier AttributeArgs { } [ ] UpdateOp ArithOp ArithOp ArithOp LogicOp BitOp BitOp BitOp CompareOp CompareOp CompareOp > CompareOp BitOp UpdateOp , Number CharLiteral AttributeArgs VirtualSpecifier BaseClassClause Access virtual FieldDeclarationList FieldDeclaration extern static register inline thread_local AttributeSpecifier __attribute__ PointerDeclarator MsBasedModifier __based MsPointerModifier FunctionDeclarator ParameterList ParameterDeclaration PointerDeclarator FunctionDeclarator Noexcept noexcept RequiresClause requires True False ParenthesizedExpression CommaExpression LambdaExpression LambdaCaptureSpecifier TemplateParameterList OptionalParameterDeclaration TypeParameterDeclaration typename class VariadicParameterDeclaration VariadicDeclarator ReferenceDeclarator OptionalTypeParameterDeclaration VariadicTypeParameterDeclaration TemplateTemplateParameterDeclaration template AbstractFunctionDeclarator AbstractPointerDeclarator AbstractArrayDeclarator AbstractParenthesizedDeclarator AbstractReferenceDeclarator ThrowSpecifier throw TrailingReturnType CompoundStatement FunctionDefinition MsCallModifier TryStatement try CatchClause catch LinkageSpecification Declaration InitDeclarator InitializerList InitializerPair SubscriptDesignator FieldDesignator ExportDeclaration export ImportDeclaration import ModuleName PartitionName HeaderName CaseStatement case default LabeledStatement StatementIdentifier ExpressionStatement IfStatement if ConditionClause Declaration else SwitchStatement switch DoStatement do while WhileStatement ForStatement for ReturnStatement return BreakStatement break ContinueStatement continue GotoStatement goto CoReturnStatement co_return CoYieldStatement co_yield AttributeStatement ForRangeLoop AliasDeclaration using TypeDefinition typedef PointerDeclarator FunctionDeclarator ArrayDeclarator ParenthesizedDeclarator ThrowStatement NamespaceDefinition namespace ScopedIdentifier Identifier OperatorName operator ArithOp BitOp CompareOp LogicOp new delete co_await ConceptDefinition concept UsingDeclaration enum StaticAssertDeclaration static_assert ConcatenatedString TemplateDeclaration FriendDeclaration friend union FunctionDefinition ExplicitFunctionSpecifier explicit FieldInitializerList FieldInitializer DefaultMethodClause DeleteMethodClause FunctionDefinition OperatorCast operator TemplateInstantiation FunctionDefinition FunctionDefinition Declaration ModuleDeclaration module RequiresExpression RequirementList SimpleRequirement TypeRequirement CompoundRequirement ReturnTypeRequirement ConstraintConjuction LogicOp ConstraintDisjunction LogicOp ArrayDeclarator ParenthesizedDeclarator ReferenceDeclarator TemplateFunction OperatorName StructuredBindingDeclarator ArrayDeclarator ParenthesizedDeclarator ReferenceDeclarator BitfieldClause FunctionDefinition FunctionDefinition Declaration FunctionDefinition Declaration AccessSpecifier UnionSpecifier ClassSpecifier EnumSpecifier SizedTypeSpecifier TypeSize EnumeratorList Enumerator DependentType Decltype decltype auto PlaceholderTypeSpecifier ParameterPackExpansion ParameterPackExpansion FieldIdentifier PointerExpression SubscriptExpression BinaryExpression ArithOp LogicOp LogicOp BitOp UnaryExpression LogicOp BitOp UpdateExpression CastExpression SizeofExpression sizeof CoAwaitExpression CompoundLiteralExpression NULL NewExpression new NewDeclarator DeleteExpression delete ParameterPackExpansion nullptr this UserDefinedLiteral ParamPack #define PreprocArg #if #ifdef #ifndef #else #endif #elif PreprocDirectiveName Macro Program",maxTerm:425,nodeProps:[["group",-35,1,8,11,14,15,16,18,71,72,100,101,102,104,191,208,229,242,243,270,271,272,277,280,281,282,284,285,286,287,290,292,293,294,295,296,"Expression",-13,17,24,25,26,42,255,256,257,258,262,263,265,266,"Type",-19,126,129,147,150,152,153,158,160,163,164,166,168,170,172,174,176,178,179,188,"Statement"],["isolate",-4,4,5,8,10,""]],propSources:[UAe],skippedNodes:[0,3,4,5,6,7,10,297,298,299,300,301,302,303,304,305,306,347,348],repeatNodeCount:41,tokenData:"&*r7ZR!UOX$eXY({YZ.gZ]$e]^+P^p$epq({qr.}rs0}st2ktu$euv!7dvw!9bwx!;exy!O{|!?R|}!AV}!O!BQ!O!P!DX!P!Q#+y!Q!R#Az!R![$(x![!]$Ag!]!^$Cc!^!_$D^!_!`%1W!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jOY$eZr$ers%^sw$ewx(Ox#O$e#O#P&f#P;'S$e;'S;=`(u<%lO$e(]&&nc)ZW(pQ%[!b'RP'f&jOX$eXY&'yZp$epq&'yqr$ers%^sw$ewx(Ox!c$e!c!}&)_!}#O$e#O#P&f#P#R$e#R#S&)_#S#T$e#T#o&)_#o;'S$e;'S;=`(u<%lO$e&y&(Sc)ZW(pQ'f&jOX$eXY&'yZp$epq&'yqr$ers%^sw$ewx(Ox!c$e!c!}&)_!}#O$e#O#P&f#P#R$e#R#S&)_#S#T$e#T#o&)_#o;'S$e;'S;=`(u<%lO$e&y&)jb)ZW(pQdT'f&jOY$eZr$ers%^sw$ewx(Ox!Q$e!Q![&)_![!c$e!c!}&)_!}#O$e#O#P&f#P#R$e#R#S&)_#S#T$e#T#o&)_#o;'S$e;'S;=`(u<%lO$e",tokenizers:[MAe,LAe,0,1,2,3,4,5,6,7,8,9],topRules:{Program:[0,307]},dynamicPrecedences:{87:1,94:1,119:1,184:1,187:-10,240:-10,241:1,244:-1,246:-10,247:1,262:-1,267:2,268:2,306:-10,365:3,417:1,418:3,419:1,420:1},specialized:[{term:356,get:e=>XAe[e]||-1},{term:32,get:e=>zAe[e]||-1},{term:66,get:e=>BAe[e]||-1},{term:363,get:e=>FAe[e]||-1}],tokenPrec:24891}),bj=Yn.define({name:"cpp",parser:WAe.configure({props:[lr.add({IfStatement:Gn({except:/^\s*({|else\b)/}),TryStatement:Gn({except:/^\s*({|catch)\b/}),LabeledStatement:Lb,CaseStatement:e=>e.baseIndent+e.unit,BlockComment:()=>null,CompoundStatement:Ia({closing:"}"}),Statement:Gn({except:/^{/})}),cr.add({"DeclarationList CompoundStatement EnumeratorList FieldDeclarationList InitializerList":ea,BlockComment(e){return{from:e.from+2,to:e.to-2}}})]}),languageData:{commentTokens:{line:"//",block:{open:"/*",close:"*/"}},indentOnInput:/^\s*(?:case |default:|\{|\})$/,closeBrackets:{stringPrefixes:["L","u","U","u8","LR","UR","uR","u8R","R"]}}});function VAe(){return new Nn(bj)}const yj=Object.freeze(Object.defineProperty({__proto__:null,cpp:VAe,cppLanguage:bj},Symbol.toStringTag,{value:"Module"})),YAe=177,jAe=179,qAe=184,GAe=12,ZAe=13,HAe=17,KAe=20,JAe=25,eIe=53,tIe=95,nIe=142,rIe=144,iIe=145,aIe=148,oIe=10,sIe=13,lIe=32,cIe=9,vj=47,uIe=41,dIe=125,OIe=new $t((e,t)=>{for(let n=0,r=e.next;(t.context&&(r<0||r==oIe||r==sIe||r==vj&&e.peek(n+1)==vj)||r==uIe||r==dIe)&&e.acceptToken(YAe),!(r!=lIe&&r!=cIe);)r=e.peek(++n)},{contextual:!0});let fIe=new Set([tIe,qAe,KAe,GAe,HAe,rIe,iIe,nIe,aIe,ZAe,eIe,JAe]);const pIe=new Du({start:!1,shift:(e,t)=>t==jAe?e:fIe.has(t)}),hIe=Vn({"func interface struct chan map const type var":U.definitionKeyword,"import package":U.moduleKeyword,"switch for go select return break continue goto fallthrough case if else defer":U.controlKeyword,range:U.keyword,Bool:U.bool,String:U.string,Rune:U.character,Number:U.number,Nil:U.null,VariableName:U.variableName,DefName:U.definition(U.variableName),TypeName:U.typeName,LabelName:U.labelName,FieldName:U.propertyName,"FunctionDecl/DefName":U.function(U.definition(U.variableName)),"TypeSpec/DefName":U.definition(U.typeName),"CallExpr/VariableName":U.function(U.variableName),LineComment:U.lineComment,BlockComment:U.blockComment,LogicOp:U.logicOperator,ArithOp:U.arithmeticOperator,BitOp:U.bitwiseOperator,"DerefOp .":U.derefOperator,"UpdateOp IncDecOp":U.updateOperator,CompareOp:U.compareOperator,"= :=":U.definitionOperator,"<-":U.operator,'~ "*"':U.modifier,"; ,":U.separator,"... :":U.punctuation,"( )":U.paren,"[ ]":U.squareBracket,"{ }":U.brace}),mIe={__proto__:null,package:10,import:18,true:380,false:380,nil:383,struct:48,func:68,interface:78,chan:94,map:118,make:157,new:159,const:204,type:212,var:224,if:236,else:238,switch:242,case:248,default:250,for:260,range:266,go:270,select:274,return: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z'|Q*[(cS*^(i-[Q+P*`R-c-dS#w|!pS$w!j-TQ&T#xQ(R&QQ(W&UR(X&VT%|#u&OhqOScw!U!V#O#k#n&|'Y+gU$Q!R$R&jU$W!T$X&uQ$e!WY%y#u&O'})|*wQ)`']V-S'W)W*kS&[#y&]S*R(S(oR*z*QY&Y#y&](S(o*QR*W(['``OSWYacmnw!O!U!V!W!X!Z!_!h!q!t!z#O#Q#S#T#V#^#_#`#a#b#c#e#h#i#j#k#n#u#v#y#|$P$Q$T$W$f$v$x%W%Y%a%c%x%y&O&W&]&`&g&m&s&x&y&|'P'R'T'U'W'X'Y']'a'b'e'o'r'w'|'}(S([(c(i(k(o(t(|)V)W)i)l)s)|*Q*`*h*k*l*n*o*p*r*w+R+g+j+l+|+},Q,R,S,T,U,V,W,X,Y,Z,[,],^,_,`,a,b,c,h,{,|,}-O-P-Q-U-V-W-X-Y-Z-[-]-^-_-dS&_#}&dW(S&S*S*|+^Q(e&bQ(o&lR*x*PS%U!t*`R+q+jR%S!qQ#PcQ(}&|Q)Z'YR+n+ghpOScw!U!V#O#k#n&|'Y+gQ$d!WQ$n!ZQ%g#VU%p#i'T,bU%q#j'U,cQ(j&gQ(u&sQ)Q'PQ)_']Q)y'wQ*_(kQ*a(tV-R'W)W*kT(U&S&l",nodeNames:"⚠ LineComment BlockComment SourceFile PackageClause package DefName ; ImportDecl import ImportSpec . String ) ( SpecList ExprStatement Number Bool Nil Rune VariableName TypedLiteral StructType struct } { StructBody FieldDecl FieldName , PointerType * FunctionType func Parameters Parameter ... InterfaceType interface InterfaceBody MethodElem UnderlyingType ~ TypeElem LogicOp ChannelType chan <- ParenthesizedType QualifiedType TypeName ParameterizedType ] [ TypeArgs ArrayType SliceType MapType map LiteralValue Element Key : Element Key ParenthesizedExpr FunctionLiteral Block Conversion SelectorExpr IndexExpr SliceExpr TypeAssertion CallExpr ParameterizedExpr Arguments CallExpr make new Arguments UnaryExp ArithOp LogicOp BitOp DerefOp BinaryExp ArithOp BitOp BitOp CompareOp LogicOp LogicOp SendStatement IncDecStatement IncDecOp Assignment = UpdateOp VarDecl := ConstDecl const ConstSpec SpecList TypeDecl type TypeSpec TypeParams TypeParam SpecList VarDecl var VarSpec SpecList LabeledStatement LabelName IfStatement if else SwitchStatement switch SwitchBlock Case case default TypeSwitchStatement SwitchBlock Case ForStatement for ForClause RangeClause range GoStatement go SelectStatement select SelectBlock Case ReceiveStatement ReturnStatement return GotoStatement break continue goto FallthroughStatement fallthrough DeferStatement defer FunctionDecl MethodDecl",maxTerm:218,context:pIe,nodeProps:[["isolate",-3,2,12,20,""],["group",-18,12,17,18,19,20,21,22,66,67,69,70,71,72,73,74,77,81,86,"Expr",-20,16,68,93,94,96,99,101,105,111,115,117,120,126,129,134,136,141,143,147,149,"Statement",-12,23,31,33,38,46,49,50,51,52,56,57,58,"Type"],["openedBy",13,"(",25,"{",53,"["],["closedBy",14,")",26,"}",54,"]"]],propSources:[hIe],skippedNodes:[0,1,2,153],repeatNodeCount:23,tokenData:":b~RvXY#iYZ#i]^#ipq#iqr#zrs$Xuv&Pvw&^wx&yxy(qyz(vz{({{|)T|})e}!O)j!O!P)u!P!Q+}!Q!R,y!R![-t![!]2^!]!^2k!^!_2p!_!`3]!`!a3e!c!}3x!}#O4j#P#Q4o#Q#R4t#R#S4|#S#T9X#T#o3x#o#p9q#p#q9v#q#r:W#r#s:]$g;'S3x;'S;=`4d<%lO3x~#nS$y~XY#iYZ#i]^#ipq#iU$PP%hQ!_!`$SS$XO!|S~$^W[~OY$XZr$Xrs$vs#O$X#O#P${#P;'S$X;'S;=`%y<%lO$X~${O[~~%ORO;'S$X;'S;=`%X;=`O$X~%^X[~OY$XZr$Xrs$vs#O$X#O#P${#P;'S$X;'S;=`%y;=`<%l$X<%lO$X~%|P;=`<%l$X~&UP%l~!_!`&X~&^O#U~~&cR%j~vw&l!_!`&X#Q#R&q~&qO%p~~&vP%o~!_!`&X~'OWd~OY&yZw&ywx'hx#O&y#O#P'm#P;'S&y;'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$S~3jQ!|S!_!`$S!`!a3p~3uP%n~!_!`&X~3}V%O~!Q![3x!c!}3x#R#S3x#T#o3x$g;'S3x;'S;=`4d<%lO3x~4gP;=`<%l3x~4oO!W~~4tO!V~~4yP%i~!_!`&X~5RV%O~!Q![5h!c!}3x#R#S3x#T#o3x$g;'S3x;'S;=`4d<%lO3x~5o^aQ%O~!O!P*`!Q![5h!c!g3x!g!h6k!h!}3x#R#S4|#T#X3x#X#Y6k#Y#]3x#]#^8k#^#o3x$g;'S3x;'S;=`4d<%lO3x~6pX%O~{|+T}!O+T!Q![7]!c!}3x#R#S8P#T#o3x$g;'S3x;'S;=`4d<%lO3x~7dXaQ%O~!Q![7]!c!}3x#R#S8P#T#]3x#]#^8k#^#o3x$g;'S3x;'S;=`4d<%lO3x~8UV%O~!Q![7]!c!}3x#R#S3x#T#o3x$g;'S3x;'S;=`4d<%lO3x~8rVaQ%O~!Q![3x!c!}3x#R#S3x#T#o3x$g;'S3x;'S;=`4d<%lO3x~9[TO#S9X#S#T$v#T;'S9X;'S;=`9k<%lO9X~9nP;=`<%l9X~9vOj~~9{Q%`~!_!`&X#p#q:R~:WO%q~~:]Oi~~:bO{~",tokenizers:[OIe,1,2,new po("j~RQYZXz{^~^O$|~~aP!P!Qd~iO$}~~",25,181)],topRules:{SourceFile:[0,3]},dynamicPrecedences:{19:1,51:-1,55:2,69:-1,108:-1},specialized:[{term:184,get:e=>mIe[e]||-1}],tokenPrec:5451}),Sj=[Mt("func ${name}(${params}) ${type} {\n ${}\n}",{label:"func",detail:"declaration",type:"keyword"}),Mt("func (${receiver}) ${name}(${params}) ${type} {\n ${}\n}",{label:"func",detail:"method declaration",type:"keyword"}),Mt("var ${name} = ${value}",{label:"var",detail:"declaration",type:"keyword"}),Mt("type ${name} ${type}",{label:"type",detail:"declaration",type:"keyword"}),Mt("const ${name} = ${value}",{label:"const",detail:"declaration",type:"keyword"}),Mt("type ${name} = ${type}",{label:"type",detail:"alias declaration",type:"keyword"}),Mt("for ${init}; ${test}; ${update} {\n ${}\n}",{label:"for",detail:"loop",type:"keyword"}),Mt("for ${i} := range ${value} {\n ${}\n}",{label:"for",detail:"range",type:"keyword"}),Mt(`select { \${} }`,{label:"select",detail:"statement",type:"keyword"}),Mt("case ${}:\n${}",{label:"case",type:"keyword"}),Mt("switch ${} {\n ${}\n}",{label:"switch",detail:"statement",type:"keyword"}),Mt("switch ${}.(${type}) {\n ${}\n}",{label:"switch",detail:"type statement",type:"keyword"}),Mt("if ${} {\n ${}\n}",{label:"if",detail:"block",type:"keyword"}),Mt(`if \${} { diff --git a/js/model_apply.js b/js/model_apply.js index 8e6fd619..f124a9aa 100644 --- a/js/model_apply.js +++ b/js/model_apply.js @@ -3,28 +3,43 @@ import { app } from "../../scripts/app.js"; import './bizyair_frontend.js' import { hideWidget } from './subassembly/tools.js' +const possibleWidgetNames=[ + "lora_name", + "control_net_name" +] function createSetWidgetCallback(modelType) { return function setWidgetCallback() { - const lora_name = this.widgets.find(widget => widget.name === "lora_name"); - const model_widget = this.widgets.find(widget => widget.name === "model_version_id"); - if (lora_name) { - const node = this; - lora_name.value = lora_name.value || "to choose" - lora_name.mouse = function(e, pos, canvas) { + const targetWidget = this.widgets.find(widget => possibleWidgetNames.includes(widget.name)); + if (targetWidget) { + targetWidget.value = targetWidget.value || "to choose" + targetWidget.mouse = function(e, pos, canvas) { try { if (e.type === "pointerdown" || e.type === "mousedown" || e.type === "click" || e.type === "pointerup") { e.preventDefault(); e.stopPropagation(); + e.widgetClick = true; + + const currentNode = this.node; + + if (!currentNode || !currentNode.widgets) { + console.warn("Node or widgets not available"); + return false; + } if (typeof bizyAirLib !== 'undefined' && typeof bizyAirLib.showModelSelect === 'function') { bizyAirLib.showModelSelect({ modelType: [modelType], selectedBaseModels: [], onApply: (version, model) => { - if (model && model_widget && version) { - lora_name.value = model; - model_widget.value = version.id; - node.setDirtyCanvas(true); + if (!currentNode || !currentNode.widgets) return; + + const currentLora = currentNode.widgets.find(widget => possibleWidgetNames.includes(widget.name)); + const currentModel = currentNode.widgets.find(w => w.name === "model_version_id"); + + if (model && currentModel && version) { + currentLora.value = model; + currentModel.value = version.id; + currentNode.setDirtyCanvas(true); } } }); @@ -37,23 +52,37 @@ function createSetWidgetCallback(modelType) { console.error("Error handling mouse event:", error); } }; - lora_name.options = lora_name.options || {}; - lora_name.options.values = () => []; - lora_name.options.editable = false; - lora_name.clickable = true; - lora_name.processMouse = true; + + targetWidget.node = this; + targetWidget.options = targetWidget.options || {}; + targetWidget.options.values = () => []; + targetWidget.options.editable = false; + targetWidget.clickable = true; + targetWidget.processMouse = true; } } } function setupNodeMouseBehavior(node, modelType) { hideWidget(node, "model_version_id"); - let lastClickTime = 0; - const DEBOUNCE_DELAY = 300; + + if (!node._bizyairState) { + node._bizyairState = { + lastClickTime: 0, + DEBOUNCE_DELAY: 300, + original_onMouseDown: node.onMouseDown + }; + } + node.onMouseDown = function(e, pos, canvas) { - const lora_name = this.widgets.find(widget => widget.name === "lora_name") - const model_widget = this.widgets.find(widget => widget.name === "model_version_id") // hidden - if (pos[1] - lora_name.last_y > 0 && pos[1] - lora_name.last_y < 20) { + if (e.widgetClick) { + return this._bizyairState.original_onMouseDown?.apply(this, arguments); + } + + + + const targetWidget = this.widgets.find(widget => possibleWidgetNames.includes(widget.name)); + if (targetWidget && pos[1] - targetWidget.last_y > 0 && pos[1] - targetWidget.last_y < 20) { const litecontextmenu = document.querySelector('.litegraph.litecontextmenu') if (litecontextmenu) { litecontextmenu.style.display = 'none' @@ -63,24 +92,33 @@ function setupNodeMouseBehavior(node, modelType) { if (e.button !== 0) { return false; } + const currentTime = new Date().getTime(); - if (currentTime - lastClickTime < DEBOUNCE_DELAY) { + if (currentTime - this._bizyairState.lastClickTime < this._bizyairState.DEBOUNCE_DELAY) { return false; } - lastClickTime = currentTime; + this._bizyairState.lastClickTime = currentTime; + + const currentNode = this; bizyAirLib.showModelSelect({ modelType: [modelType], selectedBaseModels: [], onApply: (version, model) => { - if (model && model_widget && lora_name && version) { - lora_name.value = model - model_widget.value = version.id + if (!currentNode || !currentNode.widgets) return; + + const currentLora = currentNode.widgets.find(widget => possibleWidgetNames.includes(widget.name)); + const currentModel = currentNode.widgets.find(w => w.name === "model_version_id"); + + if (model && currentModel && version) { + currentLora.value = model; + currentModel.value = version.id; + currentNode.setDirtyCanvas(true); } } - }) + }); return false; } else { - return original_onMouseDown?.apply(this, arguments); + return this._bizyairState.original_onMouseDown?.apply(this, arguments); } } } @@ -117,7 +155,7 @@ app.registerExtension({ nodeType.prototype.onNodeCreated = function() { try { const result = onNodeCreated?.apply(this, arguments); - createSetWidgetCallback("LoRA").call(this); + createSetWidgetCallback("Controlnet").call(this); return result; } catch (error) { console.error("Error in node creation:", error); @@ -128,7 +166,7 @@ app.registerExtension({ async nodeCreated(node) { if (node?.comfyClass === "BizyAir_ControlNetLoader") { - setupNodeMouseBehavior(node, "LoRA"); + setupNodeMouseBehavior(node, "Controlnet"); } } })