4 lines
36 KiB
JavaScript
4 lines
36 KiB
JavaScript
import{bY as yt,n as ge,bf as it,c as u,A as ue,bZ as X,y as Z,z as T,m as ie,x as Pe,b_ as Xe,b$ as _t,bN as Ae,R as pe,ai as se,c0 as wt,r as K,N as Se,c1 as rt,G as Ye,ad as ae,c2 as bt,c3 as kt,V as x,ac as Ot,c4 as Fe,O as ye,K as Et,c5 as Lt,J as me,c6 as $t,c7 as Pt,bX as St,c8 as Ft,c9 as It,q as Ie,ca as Ct,cb as Ce,o as ut,ax as xt,$ as ze,I as xe,ak as Mt,E as Q,cc as Dt,cd as Tt,Q as At,d as ct,ce as zt,cf as Nt,S as O,T as C,a2 as m,Y as B,U as A,a0 as oe,a1 as k,cg as jt,X as Y,W as E,a6 as ve,a5 as Ke,ae as Je,a4 as _e,ch as Oe,a3 as Wt,aj as Bt,ci as Ht,cj as Ut,M as Vt,aL as qt,ck as Gt,cl as Xt,aN as Yt,aO as Kt,Z as dt}from"./index-a0a34372.js";import{u as he,e as Me,g as W,f as Qe,h as te,r as Jt,t as Ee,i as Qt,s as Ze,j as we,_ as Zt}from"./FileItem-bc5ed3c6.js";import{M as ft,c as vt,m as De,b as Te,d as Rt,e as en,f as tn}from"./functionalCallableComp-dd44afea.js";import{C as nn,g as ln}from"./shortcut-148c4bf5.js";/* empty css */import{_ as an}from"./index-ecf61b1a.js";import{D as on}from"./index-76dd5c79.js";var sn="Expected a function";function rn(e,t,n){var l=!0,i=!0;if(typeof e!="function")throw new TypeError(sn);return yt(n)&&(l="leading"in n?!!n.leading:l,i="trailing"in n?!!n.trailing:i),ge(e,t,{leading:l,maxWait:t,trailing:i})}const re=(...e)=>{document.addEventListener(...e),it(()=>document.removeEventListener(...e))};var un={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M855 160.1l-189.2 23.5c-6.6.8-9.3 8.8-4.7 13.5l54.7 54.7-153.5 153.5a8.03 8.03 0 000 11.3l45.1 45.1c3.1 3.1 8.2 3.1 11.3 0l153.6-153.6 54.7 54.7a7.94 7.94 0 0013.5-4.7L863.9 169a7.9 7.9 0 00-8.9-8.9zM416.6 562.3a8.03 8.03 0 00-11.3 0L251.8 715.9l-54.7-54.7a7.94 7.94 0 00-13.5 4.7L160.1 855c-.6 5.2 3.7 9.5 8.9 8.9l189.2-23.5c6.6-.8 9.3-8.8 4.7-13.5l-54.7-54.7 153.6-153.6c3.1-3.1 3.1-8.2 0-11.3l-45.2-45z"}}]},name:"arrows-alt",theme:"outlined"};const cn=un;function Re(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?Object(arguments[t]):{},l=Object.keys(n);typeof Object.getOwnPropertySymbols=="function"&&(l=l.concat(Object.getOwnPropertySymbols(n).filter(function(i){return Object.getOwnPropertyDescriptor(n,i).enumerable}))),l.forEach(function(i){dn(e,i,n[i])})}return e}function dn(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var Ne=function(t,n){var l=Re({},t,n.attrs);return u(ue,Re({},l,{icon:cn}),null)};Ne.displayName="ArrowsAltOutlined";Ne.inheritAttrs=!1;const fn=Ne;var vn={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M909.3 506.3L781.7 405.6a7.23 7.23 0 00-11.7 5.7V476H548V254h64.8c6 0 9.4-7 5.7-11.7L517.7 114.7a7.14 7.14 0 00-11.3 0L405.6 242.3a7.23 7.23 0 005.7 11.7H476v222H254v-64.8c0-6-7-9.4-11.7-5.7L114.7 506.3a7.14 7.14 0 000 11.3l127.5 100.8c4.7 3.7 11.7.4 11.7-5.7V548h222v222h-64.8c-6 0-9.4 7-5.7 11.7l100.8 127.5c2.9 3.7 8.5 3.7 11.3 0l100.8-127.5c3.7-4.7.4-11.7-5.7-11.7H548V548h222v64.8c0 6 7 9.4 11.7 5.7l127.5-100.8a7.3 7.3 0 00.1-11.4z"}}]},name:"drag",theme:"outlined"};const pn=vn;function et(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?Object(arguments[t]):{},l=Object.keys(n);typeof Object.getOwnPropertySymbols=="function"&&(l=l.concat(Object.getOwnPropertySymbols(n).filter(function(i){return Object.getOwnPropertyDescriptor(n,i).enumerable}))),l.forEach(function(i){mn(e,i,n[i])})}return e}function mn(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var je=function(t,n){var l=et({},t,n.attrs);return u(ue,et({},l,{icon:pn}),null)};je.displayName="DragOutlined";je.inheritAttrs=!1;const gn=je;var hn={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M391 240.9c-.8-6.6-8.9-9.4-13.6-4.7l-43.7 43.7L200 146.3a8.03 8.03 0 00-11.3 0l-42.4 42.3a8.03 8.03 0 000 11.3L280 333.6l-43.9 43.9a8.01 8.01 0 004.7 13.6L401 410c5.1.6 9.5-3.7 8.9-8.9L391 240.9zm10.1 373.2L240.8 633c-6.6.8-9.4 8.9-4.7 13.6l43.9 43.9L146.3 824a8.03 8.03 0 000 11.3l42.4 42.3c3.1 3.1 8.2 3.1 11.3 0L333.7 744l43.7 43.7A8.01 8.01 0 00391 783l18.9-160.1c.6-5.1-3.7-9.4-8.8-8.8zm221.8-204.2L783.2 391c6.6-.8 9.4-8.9 4.7-13.6L744 333.6 877.7 200c3.1-3.1 3.1-8.2 0-11.3l-42.4-42.3a8.03 8.03 0 00-11.3 0L690.3 279.9l-43.7-43.7a8.01 8.01 0 00-13.6 4.7L614.1 401c-.6 5.2 3.7 9.5 8.8 8.9zM744 690.4l43.9-43.9a8.01 8.01 0 00-4.7-13.6L623 614c-5.1-.6-9.5 3.7-8.9 8.9L633 783.1c.8 6.6 8.9 9.4 13.6 4.7l43.7-43.7L824 877.7c3.1 3.1 8.2 3.1 11.3 0l42.4-42.3c3.1-3.1 3.1-8.2 0-11.3L744 690.4z"}}]},name:"fullscreen-exit",theme:"outlined"};const yn=hn;function tt(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?Object(arguments[t]):{},l=Object.keys(n);typeof Object.getOwnPropertySymbols=="function"&&(l=l.concat(Object.getOwnPropertySymbols(n).filter(function(i){return Object.getOwnPropertyDescriptor(n,i).enumerable}))),l.forEach(function(i){_n(e,i,n[i])})}return e}function _n(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var We=function(t,n){var l=tt({},t,n.attrs);return u(ue,tt({},l,{icon:yn}),null)};We.displayName="FullscreenExitOutlined";We.inheritAttrs=!1;const wn=We;var bn={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M290 236.4l43.9-43.9a8.01 8.01 0 00-4.7-13.6L169 160c-5.1-.6-9.5 3.7-8.9 8.9L179 329.1c.8 6.6 8.9 9.4 13.6 4.7l43.7-43.7L370 423.7c3.1 3.1 8.2 3.1 11.3 0l42.4-42.3c3.1-3.1 3.1-8.2 0-11.3L290 236.4zm352.7 187.3c3.1 3.1 8.2 3.1 11.3 0l133.7-133.6 43.7 43.7a8.01 8.01 0 0013.6-4.7L863.9 169c.6-5.1-3.7-9.5-8.9-8.9L694.8 179c-6.6.8-9.4 8.9-4.7 13.6l43.9 43.9L600.3 370a8.03 8.03 0 000 11.3l42.4 42.4zM845 694.9c-.8-6.6-8.9-9.4-13.6-4.7l-43.7 43.7L654 600.3a8.03 8.03 0 00-11.3 0l-42.4 42.3a8.03 8.03 0 000 11.3L734 787.6l-43.9 43.9a8.01 8.01 0 004.7 13.6L855 864c5.1.6 9.5-3.7 8.9-8.9L845 694.9zm-463.7-94.6a8.03 8.03 0 00-11.3 0L236.3 733.9l-43.7-43.7a8.01 8.01 0 00-13.6 4.7L160.1 855c-.6 5.1 3.7 9.5 8.9 8.9L329.2 845c6.6-.8 9.4-8.9 4.7-13.6L290 787.6 423.7 654c3.1-3.1 3.1-8.2 0-11.3l-42.4-42.4z"}}]},name:"fullscreen",theme:"outlined"};const kn=bn;function nt(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?Object(arguments[t]):{},l=Object.keys(n);typeof Object.getOwnPropertySymbols=="function"&&(l=l.concat(Object.getOwnPropertySymbols(n).filter(function(i){return Object.getOwnPropertyDescriptor(n,i).enumerable}))),l.forEach(function(i){On(e,i,n[i])})}return e}function On(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var Be=function(t,n){var l=nt({},t,n.attrs);return u(ue,nt({},l,{icon:kn}),null)};Be.displayName="FullscreenOutlined";Be.inheritAttrs=!1;const En=Be;var Ln={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M603.3 327.5l-246 178a7.95 7.95 0 000 12.9l246 178c5.3 3.8 12.7 0 12.7-6.5V643c0-10.2-4.9-19.9-13.2-25.9L457.4 512l145.4-105.2c8.3-6 13.2-15.6 13.2-25.9V334c0-6.5-7.4-10.3-12.7-6.5z"}},{tag:"path",attrs:{d:"M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm0 820c-205.4 0-372-166.6-372-372s166.6-372 372-372 372 166.6 372 372-166.6 372-372 372z"}}]},name:"left-circle",theme:"outlined"};const $n=Ln;function lt(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?Object(arguments[t]):{},l=Object.keys(n);typeof Object.getOwnPropertySymbols=="function"&&(l=l.concat(Object.getOwnPropertySymbols(n).filter(function(i){return Object.getOwnPropertyDescriptor(n,i).enumerable}))),l.forEach(function(i){Pn(e,i,n[i])})}return e}function Pn(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var He=function(t,n){var l=lt({},t,n.attrs);return u(ue,lt({},l,{icon:$n}),null)};He.displayName="LeftCircleOutlined";He.inheritAttrs=!1;const Pl=He;var Sn={icon:{tag:"svg",attrs:{viewBox:"64 64 896 896",focusable:"false"},children:[{tag:"path",attrs:{d:"M666.7 505.5l-246-178A8 8 0 00408 334v46.9c0 10.2 4.9 19.9 13.2 25.9L566.6 512 421.2 617.2c-8.3 6-13.2 15.6-13.2 25.9V690c0 6.5 7.4 10.3 12.7 6.5l246-178c4.4-3.2 4.4-9.8 0-13z"}},{tag:"path",attrs:{d:"M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448 448-200.6 448-448S759.4 64 512 64zm0 820c-205.4 0-372-166.6-372-372s166.6-372 372-372 372 166.6 372 372-166.6 372-372 372z"}}]},name:"right-circle",theme:"outlined"};const Fn=Sn;function at(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?Object(arguments[t]):{},l=Object.keys(n);typeof Object.getOwnPropertySymbols=="function"&&(l=l.concat(Object.getOwnPropertySymbols(n).filter(function(i){return Object.getOwnPropertyDescriptor(n,i).enumerable}))),l.forEach(function(i){In(e,i,n[i])})}return e}function In(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var Ue=function(t,n){var l=at({},t,n.attrs);return u(ue,at({},l,{icon:Fn}),null)};Ue.displayName="RightCircleOutlined";Ue.inheritAttrs=!1;const Sl=Ue,Cn="/infinite_image_browsing/fe-static/assets/fullscreen-7f54b926.svg",be=()=>{const e=Array.from(document.querySelectorAll(".ant-image-preview-wrap")).find(t=>t.style.display!=="none");e?(console.log("closeImageFullscreenPreview success"),xn(e)):console.log("closeImageFullscreenPreview not found")};function xn(e){if(!(e instanceof HTMLElement))throw new Error("The provided value is not an HTMLElement.");const t=new MouseEvent("click",{view:window,bubbles:!0,cancelable:!0,target:e});e.dispatchEvent(t)}const Mn=(e,t)=>{const n=t.querySelector(`.idx-${e} .ant-image-img`);n?n.click():console.log("openImageFullscreenPreview error: not found",e,t)};function Fl(e){const{previewIdx:t,eventEmitter:n,canLoadNext:l,previewing:i,sortedFiles:c,scroller:S,props:M}=he().toRefs(),{state:F}=he();let y=null;const _=(w,d)=>{var r;i.value=w,y!=null&&!w&&d&&((r=S.value)==null||r.scrollToItem(y),y=null)},I=()=>{if(!$("next")){if(e!=null&&e.loadNext)return e.loadNext();M.value.mode==="walk"&&l.value&&(Z.info(T("loadingNextFolder")),n.value.emit("loadNextDir",!0))}};re("keydown",w=>{var d;if(i.value){let r=t.value;if(["ArrowDown","ArrowRight"].includes(w.key))for(r++;c.value[r]&&!X(c.value[r].name);)r++;else if(["ArrowUp","ArrowLeft"].includes(w.key))for(r--;c.value[r]&&!X(c.value[r].name);)r--;if(X((d=c.value[r])==null?void 0:d.name)??""){t.value=r;const P=S.value;P&&!(r>=P.$_startIndex&&r<=P.$_endIndex)&&(y=r)}I()}});const h=w=>{var r;let d=t.value;if(w==="next")for(d++;c.value[d]&&!X(c.value[d].name);)d++;else if(w==="prev")for(d--;c.value[d]&&!X(c.value[d].name);)d--;if(X((r=c.value[d])==null?void 0:r.name)??""){t.value=d;const P=S.value;P&&!(d>=P.$_startIndex&&d<=P.$_endIndex)&&(y=d)}I()},$=w=>{var r;let d=t.value;if(w==="next")for(d++;c.value[d]&&!X(c.value[d].name);)d++;else if(w==="prev")for(d--;c.value[d]&&!X(c.value[d].name);)d--;return X((r=c.value[d])==null?void 0:r.name)};return Me("removeFiles",async()=>{i.value&&!F.sortedFiles[t.value]&&be()}),{previewIdx:t,onPreviewVisibleChange:_,previewing:i,previewImgMove:h,canPreview:$}}function Le(e){return typeof e=="function"||Object.prototype.toString.call(e)==="[object Object]"&&!wt(e)}function Il(){const{currLocation:e,sortedFiles:t,currPage:n,multiSelectedIdxs:l,eventEmitter:i,walker:c}=he().toRefs(),S=()=>{l.value=[]};return re("click",()=>{W.keepMultiSelect||S()}),re("blur",()=>{W.keepMultiSelect||S()}),ie(n,S),{onFileDragStart:(_,I)=>{const h=Pe(t.value[I]);Qe.fileDragging=!0,console.log("onFileDragStart set drag file ",_,I,h);const $=[h];let w=h.type==="dir";if(l.value.includes(I)){const r=l.value.map(P=>t.value[P]);$.push(...r),w=r.some(P=>P.type==="dir")}const d={includeDir:w,loc:e.value||"search-result",path:Xe($,"fullpath").map(r=>r.fullpath),nodes:Xe($,"fullpath"),__id:"FileTransferData"};_.dataTransfer.setData("text/plain",JSON.stringify(d))},onDrop:async _=>{if(c.value)return;const I=_t(_);if(!I)return;const h=e.value;if(I.loc===h)return;const $=Ae(),w=async()=>$.pushAction(async()=>{await vt(I.path,h),i.value.emit("refresh"),pe.destroyAll()}),d=()=>$.pushAction(async()=>{await De(I.path,h),te.emit("removeFiles",{paths:I.path,loc:I.loc}),i.value.emit("refresh"),pe.destroyAll()});pe.confirm({title:T("confirm")+"?",width:"60vw",content:()=>{let r,P,D;return u("div",null,[u("div",null,[`${T("moveSelectedFilesTo")} ${h}`,u("ol",{style:{maxHeight:"50vh",overflow:"auto"}},[I.path.map(L=>u("li",null,[L.split(/[/\\]/).pop()]))])]),u(ft,null,null),u("div",{style:{display:"flex",alignItems:"center",justifyContent:"flex-end"},class:"actions"},[u(se,{onClick:pe.destroyAll},Le(r=T("cancel"))?r:{default:()=>[r]}),u(se,{type:"primary",loading:!$.isIdle,onClick:w},Le(P=T("copy"))?P:{default:()=>[P]}),u(se,{type:"primary",loading:!$.isIdle,onClick:d},Le(D=T("move"))?D:{default:()=>[D]})])])},maskClosable:!0,wrapClassName:"hidden-antd-btns-modal"})},multiSelectedIdxs:l,onFileDragEnd:()=>{Qe.fileDragging=!1}}}function Cl({openNext:e}){const t=K(!1),n=K(""),{sortedFiles:l,previewIdx:i,multiSelectedIdxs:c,stack:S,currLocation:M,spinning:F,previewing:y,stackViewEl:_,eventEmitter:I,props:h,deletedFiles:$}=he().toRefs(),w=Ye;Me("removeFiles",({paths:L,loc:o})=>{w(o)!==w(M.value)||!Se(S.value)||(L.forEach(v=>$.value.add(v)),L.filter(X).forEach(v=>$.value.add(v.replace(/\.\w+$/,".txt"))))}),Me("addFiles",({files:L,loc:o})=>{if(w(o)!==w(M.value))return;const g=Se(S.value);g&&g.files.unshift(...L)});const d=Ae(),r=async(L,o,g)=>{i.value=g,W.fullscreenPreviewInitialUrl=ae(o);const v=c.value.indexOf(g);if(L.shiftKey){if(v!==-1)c.value.splice(v,1);else{c.value.push(g),c.value.sort((z,U)=>z-U);const j=c.value[0],q=c.value[c.value.length-1];c.value=Jt(j,q+1)}L.stopPropagation()}else L.ctrlKey||L.metaKey?(v!==-1?c.value.splice(v,1):c.value.push(g),L.stopPropagation()):await e(o)},P=async(L,o,g)=>{var R,ne,de;const v=ae(o),j=M.value,q={IIB_container_id:parent.IIB_container_id},z=()=>{let f=[];return c.value.includes(g)?f=c.value.map(p=>l.value[p]):f.push(o),f},U=async f=>{if(!F.value)try{F.value=!0,await Ft(o.fullpath),we.postMessage({...q,event:"click_hidden_button",btnEleId:"iib_hidden_img_update_trigger"}),await It(),we.postMessage({...q,event:"click_hidden_button",btnEleId:`iib_hidden_tab_${f}`})}catch(p){console.error(p),Z.error("发送图像失败,请携带console的错误消息找开发者")}finally{F.value=!1}},H=`${L.key}`;if(H.startsWith("toggle-tag-")){const f=+H.split("toggle-tag-")[1],{is_remove:p}=await bt({tag_id:f,img_path:o.fullpath}),a=(ne=(R=W.conf)==null?void 0:R.all_custom_tags.find(s=>s.id===f))==null?void 0:ne.name;await Ee.refreshTags([o.fullpath]),Z.success(T(p?"removedTagFromImage":"addedTagToImage",{tag:a}));return}else if(H==="add-custom-tag")Te();else if(H.startsWith("batch-add-tag-")||H.startsWith("batch-remove-tag-")){const f=+H.split("-tag-")[1],p=H.includes("add")?"add":"remove",a=z().map(s=>s.fullpath);await kt({tag_id:f,img_paths:a,action:p}),await Ee.refreshTags(a),Z.success(T(p==="add"?"addCompleted":"removeCompleted"));return}else if(H.startsWith("copy-to-")){const f=H.split("copy-to-")[1],p=z(),a=p.map(s=>s.fullpath);await vt(a,f,!0),te.emit("addFiles",{files:p,loc:f}),Z.success(T("copySuccess"));return}else if(H.startsWith("move-to-")){const f=H.split("move-to-")[1],p=z(),a=p.map(s=>s.fullpath);await De(a,f,!0),te.emit("removeFiles",{paths:a,loc:M.value}),te.emit("addFiles",{files:p,loc:f}),Z.success(T("moveSuccess"));return}switch(L.key){case"previewInNewWindow":return window.open(v);case"copyFilePath":return me(o.fullpath);case"saveSelectedAsJson":return St(z());case"openWithDefaultApp":return Pt(o.fullpath);case"download":{const f=z();$t(f.map(p=>ae(p,!0)));break}case"copyPreviewUrl":return me(parent.document.location.origin+v);case"rename":{let f=await Rt(o.fullpath);f=Ye(f);const p=Ee.tagMap;p.set(f,p.get(o.fullpath)??[]),p.delete(o.fullpath),o.fullpath=f,o.name=f.split(/[\\/]/).pop()??"";return}case"send2txt2img":return U("txt2img");case"send2img2img":return U("img2img");case"send2inpaint":return U("inpaint");case"send2extras":return U("extras");case"send2savedDir":{const f=W.quickMovePaths.find(s=>s.key==="outdir_save");if(!f)return Z.error(T("unknownSavedDir"));const p=Lt(f.dir,(de=W.conf)==null?void 0:de.sd_cwd),a=z();await De(a.map(s=>s.fullpath),p,!0),te.emit("removeFiles",{paths:a.map(s=>s.fullpath),loc:M.value}),te.emit("addFiles",{files:a,loc:p});break}case"send2controlnet-img2img":case"send2controlnet-txt2img":{const f=L.key.split("-")[1];we.postMessage({...q,event:"send_to_control_net",type:f,url:ae(o)});break}case"send2outpaint":{n.value=await d.pushAction(()=>Fe(o.fullpath)).res;const[f,p]=(n.value||"").split(`
|
||
`);we.postMessage({...q,event:"send_to_outpaint",url:ae(o),prompt:f,negPrompt:p.slice(17)});break}case"openWithWalkMode":{Ze.set(j,S.value);const f=W.tabList[h.value.tabIdx],p={type:"local",key:ye(),path:o.fullpath,name:T("local"),stackKey:j,mode:"walk"};f.panes.push(p),f.key=p.key;break}case"openFileLocationInNewTab":case"openInNewTab":{const f=W.tabList[h.value.tabIdx],p={type:"local",key:ye(),path:L.key==="openInNewTab"?o.fullpath:Et(o.fullpath),name:T("local"),mode:"scanned-fixed"};f.panes.push(p),f.key=p.key;break}case"openOnTheRight":{Ze.set(j,S.value);let f=W.tabList[h.value.tabIdx+1];f||(f={panes:[],key:"",id:ye()},W.tabList[h.value.tabIdx+1]=f);const p={type:"local",key:ye(),path:o.fullpath,name:T("local"),stackKey:j};f.panes.push(p),f.key=p.key;break}case"send2BatchDownload":{Qt.addFiles(z());break}case"viewGenInfo":{t.value=!0,n.value=await d.pushAction(()=>Fe(o.fullpath)).res;break}case"openWithLocalFileBrowser":{await Ot(o.fullpath);break}case"deleteFiles":{const f=z(),p=async()=>{const a=f.map(s=>s.fullpath);if(await en(a),Z.success(T("deleteSuccess")),y.value){const s=ae(o)===W.fullscreenPreviewInitialUrl,ee=i.value===l.value.length-1;if((s||ee)&&(be(),await Ie(100),s&&l.value.length>1)){const J=i.value;Ie(0).then(()=>Mn(J,_.value))}}te.emit("removeFiles",{paths:a,loc:M.value})};if(f.length===1&&W.ignoredConfirmActions.deleteOneOnly)return p();await new Promise(a=>{pe.confirm({title:T("confirmDelete"),maskClosable:!0,width:"60vw",content:()=>u("div",null,[u("ol",{style:{maxHeight:"50vh",overflow:"auto"}},[f.map(s=>u("li",null,[s.fullpath.split(/[/\\]/).pop()]))]),u(ft,null,null),u(nn,{checked:W.ignoredConfirmActions.deleteOneOnly,"onUpdate:checked":s=>W.ignoredConfirmActions.deleteOneOnly=s},{default:()=>[T("deleteOneOnlySkipConfirm"),x(" ("),T("resetOnGlobalSettingsPage"),x(")")]})]),async onOk(){await p(),a()}})});break}}return{}},{isOutside:D}=rt(_);return re("keydown",L=>{var g,v,j;const o=ln(L);if(y.value){o==="Esc"&&be();const q=(g=Object.entries(W.shortcut).find(z=>z[1]===o&&z[1]))==null?void 0:g[0];if(q){L.stopPropagation(),L.preventDefault();const z=i.value,U=l.value[z];switch(q){case"delete":return P({key:"deleteFiles"},U,z);case"download":return P({key:"download"},U,z);default:{const H=(v=/^toggle_tag_(.*)$/.exec(q))==null?void 0:v[1],R=(j=W.conf)==null?void 0:j.all_custom_tags.find(ne=>ne.name===H);return R?P({key:`toggle-tag-${R.id}`},U,z):void 0}}}}else!D.value&&["Ctrl + KeyA","Cmd + KeyA"].includes(o)&&(L.preventDefault(),L.stopPropagation(),I.value.emit("selectAll"))}),{onFileItemClick:r,onContextMenuClick:P,showGenInfo:t,imageGenInfo:n,q:d}}const $e=new Map,xl=()=>{const{useEventListen:e,sortedFiles:t,getViewableAreaFiles:n}=he().toRefs(),l=K(W.defaultChangeIndchecked),i=K(W.defaultSeedChangeChecked),c=async()=>{if(await Ie(100),!l.value)return;const F=n.value().filter(_=>X(_.fullpath)&&!_.gen_info_obj);if(!F.length)return;const y=await Ct(F.map(_=>_.fullpath).filter(_=>!$e.has(_)));F.forEach(_=>{const I=y[_.fullpath]||$e.get(_.fullpath)||"";$e.set(_.fullpath,I),_.gen_info_obj=Ce(I),_.gen_info_raw=I})};e.value("viewableAreaFilesChange",c);const S=F=>{const y=t.value;return[F,i.value,y[F-1],y[F],y[F+1]]};function M(F,y,_,I){const h={diff:{},empty:!0,ownFile:"",otherFile:""};if(y+_<0||y+_>=t.value.length||t.value[y]==null||!("gen_info_obj"in t.value[y])||!("gen_info_obj"in t.value[y+_]))return h;const $=F,w=t.value[y+_].gen_info_obj;if(w==null)return h;const d=["hashes","resources"];h.diff={},h.ownFile=I.name,h.otherFile=t.value[y+_].name,h.empty=!1,i.value||d.push("seed");for(const r in $)if(!d.includes(r)){if(!(r in w)){h.diff[r]="+";continue}if($[r]!=w[r])if(r.includes("rompt")&&$[r]!=""&&w[r]!=""){const P=$[r].split(","),D=w[r].split(",");let L=0;for(const o in P)P[o]!=D[o]&&L++;h.diff[r]=L}else h.diff[r]=[$[r],w[r]]}return h}return{getGenDiff:M,changeIndchecked:l,seedChangeChecked:i,getRawGenParams:()=>c(),getGenDiffWatchDep:S}};function Dn(e,t,n,l){let i=0,c=0,S=typeof(l==null?void 0:l.width)=="number"?l.width:0,M=typeof(l==null?void 0:l.height)=="number"?l.height:0,F=typeof(l==null?void 0:l.left)=="number"?l.left:0,y=typeof(l==null?void 0:l.top)=="number"?l.top:0,_=!1;const I=o=>{o.stopPropagation(),o.preventDefault(),!(!e.value||!t.value)&&(i=o instanceof MouseEvent?o.clientX:o.touches[0].clientX,c=o instanceof MouseEvent?o.clientY:o.touches[0].clientY,S=e.value.offsetWidth,M=e.value.offsetHeight,t.value.offsetLeft,t.value.offsetTop,document.documentElement.addEventListener("mousemove",h),document.documentElement.addEventListener("touchmove",h),document.documentElement.addEventListener("mouseup",$),document.documentElement.addEventListener("touchend",$))},h=o=>{if(!e.value||!t.value)return;let g=S+((o instanceof MouseEvent?o.clientX:o.touches[0].clientX)-i),v=M+((o instanceof MouseEvent?o.clientY:o.touches[0].clientY)-c);e.value.offsetLeft+g>window.innerWidth&&(g=window.innerWidth-e.value.offsetLeft),e.value.offsetTop+v>window.innerHeight&&(v=window.innerHeight-e.value.offsetTop),e.value.style.width=`${g}px`,e.value.style.height=`${v}px`,l!=null&&l.onResize&&l.onResize(g,v)},$=()=>{document.documentElement.removeEventListener("mousemove",h),document.documentElement.removeEventListener("touchmove",h),document.documentElement.removeEventListener("mouseup",$),document.documentElement.removeEventListener("touchend",$)},w=o=>{o.stopPropagation(),o.preventDefault(),!(!e.value||!n.value)&&(_=!0,F=e.value.offsetLeft,y=e.value.offsetTop,i=o instanceof MouseEvent?o.clientX:o.touches[0].clientX,c=o instanceof MouseEvent?o.clientY:o.touches[0].clientY,document.documentElement.addEventListener("mousemove",d),document.documentElement.addEventListener("touchmove",d),document.documentElement.addEventListener("mouseup",r),document.documentElement.addEventListener("touchend",r))},d=o=>{if(!e.value||!n.value||!_)return;const g=F+((o instanceof MouseEvent?o.clientX:o.touches[0].clientX)-i),v=y+((o instanceof MouseEvent?o.clientY:o.touches[0].clientY)-c);g<0?e.value.style.left="0px":g+e.value.offsetWidth>window.innerWidth?e.value.style.left=`${window.innerWidth-e.value.offsetWidth}px`:e.value.style.left=`${g}px`,v<0?e.value.style.top="0px":v+e.value.offsetHeight>window.innerHeight?e.value.style.top=`${window.innerHeight-e.value.offsetHeight}px`:e.value.style.top=`${v}px`,l!=null&&l.onDrag&&l.onDrag(g,v)},r=()=>{_=!1,document.documentElement.removeEventListener("mousemove",d),document.documentElement.removeEventListener("touchmove",d),document.documentElement.removeEventListener("mouseup",r),document.documentElement.removeEventListener("touchend",r)},P=()=>{if(!e.value||!t.value)return;let o=e.value.offsetLeft,g=e.value.offsetTop,v=e.value.offsetWidth,j=e.value.offsetHeight;o+v>window.innerWidth&&(o=window.innerWidth-v,o<0&&(o=0,v=window.innerWidth)),g+j>window.innerHeight&&(g=window.innerHeight-j,g<0&&(g=0,j=window.innerHeight)),e.value.style.left=`${o}px`,e.value.style.top=`${g}px`,e.value.style.width=`${v}px`,e.value.style.height=`${j}px`},D=()=>{!e.value||!l||(typeof l.width=="number"&&(e.value.style.width=`${l.width}px`),typeof l.height=="number"&&(e.value.style.height=`${l.height}px`),typeof l.left=="number"&&(e.value.style.left=`${l.left}px`),typeof l.top=="number"&&(e.value.style.top=`${l.top}px`),P(),window.addEventListener("resize",P))},L=()=>{document.documentElement.removeEventListener("mousemove",h),document.documentElement.removeEventListener("touchmove",h),document.documentElement.removeEventListener("mouseup",$),document.documentElement.removeEventListener("touchend",$),document.documentElement.removeEventListener("mousemove",d),document.documentElement.removeEventListener("touchmove",d),document.documentElement.removeEventListener("mouseup",r),document.documentElement.removeEventListener("touchend",r),window.removeEventListener("resize",P)};return ut(D),it(L),ie(()=>l==null?void 0:l.disbaled,async o=>{await xt(),o!==void 0&&(o?L():D())}),ie(()=>[e.value,t.value,n.value],([o,g,v])=>{o&&g&&(g.addEventListener("mousedown",I),g.addEventListener("touchstart",I)),o&&v&&(v.addEventListener("mousedown",w),v.addEventListener("touchstart",w))}),{handleResizeMouseDown:I,handleDragMouseDown:w}}let ot=null;const Tn=()=>{var F,y;const e=ze(),t=xe(At+"fullscreen_layout",{enable:!1,panelWidth:384,alwaysOn:!0}),n=Mt(ot??((y=(F=e.conf)==null?void 0:F.app_fe_setting)==null?void 0:y.fullscreen_layout)??Pe(t.value)),l="--iib-lr-layout-info-panel-width",i=Q(()=>n.alwaysOn&&n.enable?n.panelWidth:0);ie(n,_=>{t.value=Pe(_),st(n,l,i),An(n),ot=n},{deep:!0}),ut(()=>st(n,l,i));const{enable:c,panelWidth:S,alwaysOn:M}=Dt(n);return{state:n,isLeftRightLayout:c,panelwidtrhStyleVarName:l,lrLayoutInfoPanelWidth:S,lrMenuAlwaysOn:M}},An=ge(e=>Tt("fullscreen_layout",e),300),st=ge((e,t,n)=>{e.enable?(document.body.classList.add("fullscreen-lr-layout"),document.documentElement.style.setProperty(t,`${e.panelWidth}px`),document.documentElement.style.setProperty("--iib-lr-layout-container-offset",`${n.value}px`)):(document.documentElement.style.removeProperty(t),document.documentElement.style.removeProperty("--iib-lr-layout-container-offset"),document.body.classList.remove("fullscreen-lr-layout"))},300),ce=e=>(Yt("data-v-6d84d348"),e=e(),Kt(),e),zn={key:0},Nn={class:"container"},jn={class:"action-bar"},Wn=["title"],Bn=["title"],Hn=["title"],Un=["src"],Vn={key:0,class:"icon",style:{cursor:"pointer"}},qn={key:2,"flex-placeholder":""},Gn={key:3,class:"action-bar"},Xn={key:0,class:"gen-info"},Yn={class:"info-tags"},Kn={class:"name"},Jn={class:"value"},Qn={key:0,class:"tags-container"},Zn=["onClick"],Rn={class:"lr-layout-control"},el={class:"ctrl-item"},tl={class:"ctrl-item"},nl={class:"ctrl-item"},ll=ce(()=>A("br",null,null,-1)),al=ce(()=>A("h3",null,"Prompt",-1)),ol=["innerHTML"],sl=ce(()=>A("br",null,null,-1)),il=ce(()=>A("h3",null,"Negative Prompt",-1)),rl=["innerHTML"],ul=ce(()=>A("br",null,null,-1)),cl=ce(()=>A("h3",null,"Params",-1)),dl={style:{"font-weight":"600","text-transform":"capitalize"}},fl=["onDblclick"],vl=["onDblclick"],pl=["title"],ml=ct({__name:"fullScreenContextMenu",props:{file:{},idx:{}},emits:["contextMenuClick"],setup(e,{emit:t}){const n=e;zt(a=>({"0ab4e432":m(g)?0:"46px","1b1abdcc":m(o)+"px","1b10cd44":`calc(100vw - ${m(o)}px)`}));const l=ze(),i=Nt(),c=K(),S=Q(()=>i.tagMap.get(n.file.fullpath)??[]),M=K(""),F=Ae(),y=K(""),_=Q(()=>y.value.replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">").replace(/"/g,""").replace(/'/g,"'")),I=Q(()=>_.value.split(`
|
||
`)),h=Q(()=>Ce(_.value)),$=Q(()=>{let a=Ce(_.value);return delete a.prompt,delete a.negativePrompt,a});ie(()=>{var a;return(a=n==null?void 0:n.file)==null?void 0:a.fullpath},async a=>{a&&(F.tasks.forEach(s=>s.cancel()),F.pushAction(()=>Fe(a)).res.then(s=>{y.value=s}))},{immediate:!0});const w=xe("iib@fullScreenContextMenu.prompt-tab","structedData"),d=K(),r=K(),P={left:100,top:100,width:512,height:384,expanded:!0},D=xe("fullScreenContextMenu.vue-drag",P);D.value&&(D.value.left<0||D.value.top<0)&&(D.value={...P});const{isLeftRightLayout:L,lrLayoutInfoPanelWidth:o,lrMenuAlwaysOn:g}=Tn(),v=L;Dn(c,d,r,{disbaled:v,...D.value,onDrag:ge(function(a,s){D.value={...D.value,left:a,top:s}},300),onResize:ge(function(a,s){D.value={...D.value,width:a,height:s}},300)});const j=K(!1),{isOutside:q}=rt(Q(()=>!v.value||g.value?null:j.value?c.value:Se(document.querySelectorAll(".iib-tab-edge-trigger"))));ie(q,rn(a=>{j.value=!a},300));function z(a){return a.parentNode}function U(a){if(!a)return"";const s=[],ee="BREAK",J=a.replace(/>\s/g,"> ,").replace(/\sBREAK\s/g,","+ee+",").split(/[\n,]+/).map(G=>G.trim()).filter(G=>G);let N=!1;for(let G=0;G<J.length;G++){if(J[G]===ee){s.push('<br><span class="tag" style="color:var(--zp-secondary)">BREAK</span><br>');continue}const le=J[G];N||(N=le.includes("("));const fe=["tag"];N&&fe.push("has-parentheses"),le.length<32&&fe.push("short-tag"),s.push(`<span class="${fe.join(" ")}">${le}</span>`),N&&(N=!le.includes(")"))}return s.join(l.showCommaInInfoPanel?",":" ")}re("load",a=>{const s=a.target;s.className==="ant-image-preview-img"&&(M.value=`${s.naturalWidth} x ${s.naturalHeight}`)},{capture:!0});const H=Q(()=>{const a=[{name:T("fileName"),val:n.file.name},{name:T("fileSize"),val:n.file.size}];return M.value&&a.push({name:T("resolution"),val:M.value}),a}),R=()=>{const a="Negative prompt:",s=y.value.includes(a)?y.value.split(a)[0]:I.value[0]??"";me(Oe(s.trim()))},ne=()=>document.body.requestFullscreen(),de=a=>{me(typeof a=="object"?JSON.stringify(a,null,4):a)},f=a=>{a.key.startsWith("Arrow")?(a.stopPropagation(),a.preventDefault(),document.dispatchEvent(new KeyboardEvent("keydown",a))):a.key==="Escape"&&document.fullscreenElement&&document.exitFullscreen()};re("dblclick",a=>{var s;((s=a.target)==null?void 0:s.className)==="ant-image-preview-img"&&be()});const p=Q(()=>v.value||D.value.expanded);return(a,s)=>{var Ge;const ee=on,J=se,N=Bt,G=Ht,le=Ut,fe=Vt,pt=se,Ve=an,mt=tn,gt=qt,qe=Gt,ht=Xt;return O(),C("div",{ref_key:"el",ref:c,class:Je(["full-screen-menu",{"unset-size":!m(D).expanded,lr:m(v),"always-on":m(g),"mouse-in":j.value}]),onWheelCapture:s[10]||(s[10]=Wt(()=>{},["stop"])),onKeydownCapture:f},[m(v)?(O(),C("div",zn)):B("",!0),A("div",Nn,[A("div",jn,[m(v)?B("",!0):(O(),C("div",{key:0,ref_key:"dragHandle",ref:r,class:"icon",style:{cursor:"grab"},title:m(T)("dragToMovePanel")},[u(m(gn))],8,Wn)),m(v)?B("",!0):(O(),C("div",{key:1,class:"icon",style:{cursor:"pointer"},onClick:s[0]||(s[0]=b=>m(D).expanded=!m(D).expanded),title:m(T)("clickToToggleMaximizeMinimize")},[p.value?(O(),oe(m(wn),{key:0})):(O(),oe(m(En),{key:1}))],8,Bn)),A("div",{style:{display:"flex","flex-direction":"column","align-items":"center",cursor:"grab"},class:"icon",title:m(T)("fullscreenview"),onClick:ne},[A("img",{src:m(Cn),style:{width:"21px",height:"21px","padding-bottom":"2px"},alt:""},null,8,Un)],8,Hn),u(ee,{"get-popup-container":z},{overlay:k(()=>[u(Zt,{file:a.file,idx:a.idx,"selected-tag":S.value,onContextMenuClick:s[1]||(s[1]=(b,V,ke)=>t("contextMenuClick",b,V,ke))},null,8,["file","idx","selected-tag"])]),default:k(()=>[m(D).expanded?B("",!0):(O(),C("div",Vn,[u(m(jt))]))]),_:1}),p.value?(O(),C("div",qn)):B("",!0),p.value?(O(),C("div",Gn,[u(ee,{trigger:["hover"],"get-popup-container":z},{overlay:k(()=>[u(fe,{onClick:s[2]||(s[2]=b=>t("contextMenuClick",b,a.file,a.idx))},{default:k(()=>{var b;return[((b=m(l).conf)==null?void 0:b.launch_mode)!=="server"?(O(),C(Y,{key:0},[u(N,{key:"send2txt2img"},{default:k(()=>[x(E(a.$t("sendToTxt2img")),1)]),_:1}),u(N,{key:"send2img2img"},{default:k(()=>[x(E(a.$t("sendToImg2img")),1)]),_:1}),u(N,{key:"send2inpaint"},{default:k(()=>[x(E(a.$t("sendToInpaint")),1)]),_:1}),u(N,{key:"send2extras"},{default:k(()=>[x(E(a.$t("sendToExtraFeatures")),1)]),_:1}),u(G,{key:"sendToThirdPartyExtension",title:a.$t("sendToThirdPartyExtension")},{default:k(()=>[u(N,{key:"send2controlnet-txt2img"},{default:k(()=>[x("ControlNet - "+E(a.$t("t2i")),1)]),_:1}),u(N,{key:"send2controlnet-img2img"},{default:k(()=>[x("ControlNet - "+E(a.$t("i2i")),1)]),_:1}),u(N,{key:"send2outpaint"},{default:k(()=>[x("openOutpaint")]),_:1})]),_:1},8,["title"])],64)):B("",!0),u(N,{key:"send2BatchDownload"},{default:k(()=>[x(E(a.$t("sendToBatchDownload")),1)]),_:1}),u(G,{key:"copy2target",title:a.$t("copyTo")},{default:k(()=>[(O(!0),C(Y,null,ve(m(l).quickMovePaths,V=>(O(),oe(N,{key:`copy-to-${V.dir}`},{default:k(()=>[x(E(V.zh),1)]),_:2},1024))),128))]),_:1},8,["title"]),u(G,{key:"move2target",title:a.$t("moveTo")},{default:k(()=>[(O(!0),C(Y,null,ve(m(l).quickMovePaths,V=>(O(),oe(N,{key:`move-to-${V.dir}`},{default:k(()=>[x(E(V.zh),1)]),_:2},1024))),128))]),_:1},8,["title"]),u(le),u(N,{key:"deleteFiles"},{default:k(()=>[x(E(a.$t("deleteSelected")),1)]),_:1}),u(N,{key:"previewInNewWindow"},{default:k(()=>[x(E(a.$t("previewInNewWindow")),1)]),_:1}),u(N,{key:"copyPreviewUrl"},{default:k(()=>[x(E(a.$t("copySourceFilePreviewLink")),1)]),_:1}),u(N,{key:"copyFilePath"},{default:k(()=>[x(E(a.$t("copyFilePath")),1)]),_:1})]}),_:1})]),default:k(()=>[u(J,null,{default:k(()=>[x(E(m(T)("openContextMenu")),1)]),_:1})]),_:1}),u(pt,{onClick:s[3]||(s[3]=b=>t("contextMenuClick",{key:"download"},n.file,n.idx))},{default:k(()=>[x(E(a.$t("download")),1)]),_:1}),y.value?(O(),oe(J,{key:0,onClick:s[4]||(s[4]=b=>m(me)(y.value))},{default:k(()=>[x(E(a.$t("copyPrompt")),1)]),_:1})):B("",!0),y.value?(O(),oe(J,{key:1,onClick:R},{default:k(()=>[x(E(a.$t("copyPositivePrompt")),1)]),_:1})):B("",!0)])):B("",!0)]),p.value?(O(),C("div",Xn,[A("div",Yn,[(O(!0),C(Y,null,ve(H.value,b=>(O(),C("span",{class:"info-tag",key:b.name},[A("span",Kn,E(b.name),1),A("span",Jn,E(b.val),1)]))),128))]),(Ge=m(l).conf)!=null&&Ge.all_custom_tags?(O(),C("div",Qn,[A("div",{class:"tag",onClick:s[5]||(s[5]=(...b)=>m(Te)&&m(Te)(...b)),style:Ke({"--tag-color":"var(--zp-luminous)"})},"+ "+E(a.$t("add")),5),(O(!0),C(Y,null,ve(m(l).conf.all_custom_tags,b=>(O(),C("div",{class:Je(["tag",{selected:S.value.some(V=>V.id===b.id)}]),onClick:V=>t("contextMenuClick",{key:`toggle-tag-${b.id}`},a.file,a.idx),key:b.id,style:Ke({"--tag-color":m(i).getColor(b.name)})},E(b.name),15,Zn))),128))])):B("",!0),A("div",Rn,[A("div",el,[x(E(a.$t("experimentalLRLayout"))+": ",1),u(Ve,{checked:m(v),"onUpdate:checked":s[6]||(s[6]=b=>_e(v)?v.value=b:null),size:"small"},null,8,["checked"])]),m(v)?(O(),C(Y,{key:0},[A("div",tl,[x(E(a.$t("width"))+": ",1),u(mt,{value:m(o),"onUpdate:value":s[7]||(s[7]=b=>_e(o)?o.value=b:null),style:{width:"64px"},step:16,min:128,max:1024},null,8,["value"])]),u(gt,{title:a.$t("alwaysOnTooltipInfo")},{default:k(()=>[A("div",nl,[x(E(a.$t("alwaysOn"))+": ",1),u(Ve,{checked:m(g),"onUpdate:checked":s[8]||(s[8]=b=>_e(g)?g.value=b:null),size:"small"},null,8,["checked"])])]),_:1},8,["title"])],64)):B("",!0)]),u(ht,{activeKey:m(w),"onUpdate:activeKey":s[9]||(s[9]=b=>_e(w)?w.value=b:null)},{default:k(()=>[u(qe,{key:"structedData",tab:a.$t("structuredData")},{default:k(()=>[A("div",null,[h.value.prompt?(O(),C(Y,{key:0},[ll,al,A("code",{innerHTML:U(h.value.prompt??"")},null,8,ol)],64)):B("",!0),h.value.negativePrompt?(O(),C(Y,{key:1},[sl,il,A("code",{innerHTML:U(h.value.negativePrompt??"")},null,8,rl)],64)):B("",!0)]),Object.keys($.value).length?(O(),C(Y,{key:0},[ul,cl,A("table",null,[(O(!0),C(Y,null,ve($.value,(b,V)=>(O(),C("tr",{key:V,class:"gen-info-frag"},[A("td",dl,E(V),1),typeof b=="object"?(O(),C("td",{key:0,style:{cursor:"pointer"},onDblclick:ke=>de(b)},[A("code",null,E(b),1)],40,fl)):(O(),C("td",{key:1,style:{cursor:"pointer"},onDblclick:ke=>de(m(Oe)(b))},E(m(Oe)(b)),41,vl))]))),128))])],64)):B("",!0)]),_:1},8,["tab"]),u(qe,{key:"sourceText",tab:a.$t("sourceText")},{default:k(()=>[A("code",null,E(y.value),1)]),_:1},8,["tab"])]),_:1},8,["activeKey"])])):B("",!0)]),m(D).expanded&&!m(v)?(O(),C("div",{key:1,class:"mouse-sensor",ref_key:"resizeHandle",ref:d,title:m(T)("dragToResizePanel")},[u(m(fn))],8,pl)):B("",!0)],34)}}});const Ml=dt(ml,[["__scopeId","data-v-6d84d348"]]),gl={key:0,class:"float-panel"},hl={key:0,class:"select-actions"},yl={key:1},_l=ct({__name:"MultiSelectKeep",props:{show:{type:Boolean}},emits:["selectAll","reverseSelect","clearAllSelected"],setup(e,{emit:t}){const n=ze(),l=()=>{t("clearAllSelected"),n.keepMultiSelect=!1},i=()=>{n.keepMultiSelect=!0};return(c,S)=>{const M=se;return c.show?(O(),C("div",gl,[m(n).keepMultiSelect?(O(),C("div",hl,[u(M,{size:"small",onClick:S[0]||(S[0]=F=>t("selectAll"))},{default:k(()=>[x(E(c.$t("select-all")),1)]),_:1}),u(M,{size:"small",onClick:S[1]||(S[1]=F=>t("reverseSelect"))},{default:k(()=>[x(E(c.$t("rerverse-select")),1)]),_:1}),u(M,{size:"small",onClick:S[2]||(S[2]=F=>t("clearAllSelected"))},{default:k(()=>[x(E(c.$t("clear-all-selected")),1)]),_:1}),u(M,{size:"small",onClick:l},{default:k(()=>[x(E(c.$t("exit")),1)]),_:1})])):(O(),C("div",yl,[u(M,{size:"small",type:"primary",onClick:i},{default:k(()=>[x(E(c.$t("keep-multi-selected")),1)]),_:1})]))])):B("",!0)}}});const Dl=dt(_l,[["__scopeId","data-v-b04c3508"]]);export{Pl as L,Dl as M,Sl as R,Il as a,Cl as b,Fl as c,xl as d,Ml as f,re as u};
|