3 lines
20 KiB
JavaScript
3 lines
20 KiB
JavaScript
import{c as s,a4 as F,au as Ee,ax as $e,s as pe,d as ge,r as he,c4 as ke,v as X,ag as W,bQ as Me,y as le,c5 as Se,c6 as ae,ao as re,a6 as A,o as v,k as p,l as y,B as d,z as Y,A as c,Q as oe,c7 as Pe,p as w,n as T,m as _,t as f,G as ie,I as U,R as se,H as Ce,E as xe,C as ze,X as G,Y as De,c8 as Ae,M as Te,c9 as je,ca as Ie,am as Ne,an as We,q as _e}from"./index-e8d50841.js";import{D as Fe}from"./index-ca63bd8a.js";import"./index-76502f99.js";import{j as Be,_ as He}from"./FileItem-536e74b1.js";var Ve={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 Xe=Ve;function ue(e){for(var t=1;t<arguments.length;t++){var l=arguments[t]!=null?Object(arguments[t]):{},n=Object.keys(l);typeof Object.getOwnPropertySymbols=="function"&&(n=n.concat(Object.getOwnPropertySymbols(l).filter(function(o){return Object.getOwnPropertyDescriptor(l,o).enumerable}))),n.forEach(function(o){Ye(e,o,l[o])})}return e}function Ye(e,t,l){return t in e?Object.defineProperty(e,t,{value:l,enumerable:!0,configurable:!0,writable:!0}):e[t]=l,e}var q=function(t,l){var n=ue({},t,l.attrs);return s(F,ue({},n,{icon:Xe}),null)};q.displayName="ArrowsAltOutlined";q.inheritAttrs=!1;const Ue=q;var Ge={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 qe=Ge;function ce(e){for(var t=1;t<arguments.length;t++){var l=arguments[t]!=null?Object(arguments[t]):{},n=Object.keys(l);typeof Object.getOwnPropertySymbols=="function"&&(n=n.concat(Object.getOwnPropertySymbols(l).filter(function(o){return Object.getOwnPropertyDescriptor(l,o).enumerable}))),n.forEach(function(o){Qe(e,o,l[o])})}return e}function Qe(e,t,l){return t in e?Object.defineProperty(e,t,{value:l,enumerable:!0,configurable:!0,writable:!0}):e[t]=l,e}var Q=function(t,l){var n=ce({},t,l.attrs);return s(F,ce({},n,{icon:qe}),null)};Q.displayName="DragOutlined";Q.inheritAttrs=!1;const Je=Q;var Ze={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 Ke=Ze;function de(e){for(var t=1;t<arguments.length;t++){var l=arguments[t]!=null?Object(arguments[t]):{},n=Object.keys(l);typeof Object.getOwnPropertySymbols=="function"&&(n=n.concat(Object.getOwnPropertySymbols(l).filter(function(o){return Object.getOwnPropertyDescriptor(l,o).enumerable}))),n.forEach(function(o){Re(e,o,l[o])})}return e}function Re(e,t,l){return t in e?Object.defineProperty(e,t,{value:l,enumerable:!0,configurable:!0,writable:!0}):e[t]=l,e}var J=function(t,l){var n=de({},t,l.attrs);return s(F,de({},n,{icon:Ke}),null)};J.displayName="FullscreenExitOutlined";J.inheritAttrs=!1;const et=J;var tt={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 nt=tt;function fe(e){for(var t=1;t<arguments.length;t++){var l=arguments[t]!=null?Object(arguments[t]):{},n=Object.keys(l);typeof Object.getOwnPropertySymbols=="function"&&(n=n.concat(Object.getOwnPropertySymbols(l).filter(function(o){return Object.getOwnPropertyDescriptor(l,o).enumerable}))),n.forEach(function(o){lt(e,o,l[o])})}return e}function lt(e,t,l){return t in e?Object.defineProperty(e,t,{value:l,enumerable:!0,configurable:!0,writable:!0}):e[t]=l,e}var Z=function(t,l){var n=fe({},t,l.attrs);return s(F,fe({},n,{icon:nt}),null)};Z.displayName="FullscreenOutlined";Z.inheritAttrs=!1;const at=Z;var rt={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 ot=rt;function ve(e){for(var t=1;t<arguments.length;t++){var l=arguments[t]!=null?Object(arguments[t]):{},n=Object.keys(l);typeof Object.getOwnPropertySymbols=="function"&&(n=n.concat(Object.getOwnPropertySymbols(l).filter(function(o){return Object.getOwnPropertyDescriptor(l,o).enumerable}))),n.forEach(function(o){it(e,o,l[o])})}return e}function it(e,t,l){return t in e?Object.defineProperty(e,t,{value:l,enumerable:!0,configurable:!0,writable:!0}):e[t]=l,e}var K=function(t,l){var n=ve({},t,l.attrs);return s(F,ve({},n,{icon:ot}),null)};K.displayName="LeftCircleOutlined";K.inheritAttrs=!1;const Ut=K;var st={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 ut=st;function me(e){for(var t=1;t<arguments.length;t++){var l=arguments[t]!=null?Object(arguments[t]):{},n=Object.keys(l);typeof Object.getOwnPropertySymbols=="function"&&(n=n.concat(Object.getOwnPropertySymbols(l).filter(function(o){return Object.getOwnPropertyDescriptor(l,o).enumerable}))),n.forEach(function(o){ct(e,o,l[o])})}return e}function ct(e,t,l){return t in e?Object.defineProperty(e,t,{value:l,enumerable:!0,configurable:!0,writable:!0}):e[t]=l,e}var R=function(t,l){var n=me({},t,l.attrs);return s(F,me({},n,{icon:ut}),null)};R.displayName="RightCircleOutlined";R.inheritAttrs=!1;const Gt=R;function dt(e,t,l,n){let o=0,b=0,O=typeof(n==null?void 0:n.width)=="number"?n.width:0,L=typeof(n==null?void 0:n.height)=="number"?n.height:0,C=typeof(n==null?void 0:n.left)=="number"?n.left:0,E=typeof(n==null?void 0:n.top)=="number"?n.top:0,x=!1;const H=r=>{r.stopPropagation(),r.preventDefault(),!(!e.value||!t.value)&&(o=r instanceof MouseEvent?r.clientX:r.touches[0].clientX,b=r instanceof MouseEvent?r.clientY:r.touches[0].clientY,O=e.value.offsetWidth,L=e.value.offsetHeight,t.value.offsetLeft,t.value.offsetTop,document.documentElement.addEventListener("mousemove",$),document.documentElement.addEventListener("touchmove",$),document.documentElement.addEventListener("mouseup",M),document.documentElement.addEventListener("touchend",M))},$=r=>{if(!e.value||!t.value)return;let i=O+((r instanceof MouseEvent?r.clientX:r.touches[0].clientX)-o),g=L+((r instanceof MouseEvent?r.clientY:r.touches[0].clientY)-b);e.value.offsetLeft+i>window.innerWidth&&(i=window.innerWidth-e.value.offsetLeft),e.value.offsetTop+g>window.innerHeight&&(g=window.innerHeight-e.value.offsetTop),e.value.style.width=`${i}px`,e.value.style.height=`${g}px`,n!=null&&n.onResize&&n.onResize(i,g)},M=()=>{document.documentElement.removeEventListener("mousemove",$),document.documentElement.removeEventListener("touchmove",$),document.documentElement.removeEventListener("mouseup",M),document.documentElement.removeEventListener("touchend",M)},j=r=>{r.stopPropagation(),r.preventDefault(),!(!e.value||!l.value)&&(x=!0,C=e.value.offsetLeft,E=e.value.offsetTop,o=r instanceof MouseEvent?r.clientX:r.touches[0].clientX,b=r instanceof MouseEvent?r.clientY:r.touches[0].clientY,document.documentElement.addEventListener("mousemove",k),document.documentElement.addEventListener("touchmove",k),document.documentElement.addEventListener("mouseup",S),document.documentElement.addEventListener("touchend",S))},k=r=>{if(!e.value||!l.value||!x)return;const i=C+((r instanceof MouseEvent?r.clientX:r.touches[0].clientX)-o),g=E+((r instanceof MouseEvent?r.clientY:r.touches[0].clientY)-b);i<0?e.value.style.left="0px":i+e.value.offsetWidth>window.innerWidth?e.value.style.left=`${window.innerWidth-e.value.offsetWidth}px`:e.value.style.left=`${i}px`,g<0?e.value.style.top="0px":g+e.value.offsetHeight>window.innerHeight?e.value.style.top=`${window.innerHeight-e.value.offsetHeight}px`:e.value.style.top=`${g}px`,n!=null&&n.onDrag&&n.onDrag(i,g)},S=()=>{x=!1,document.documentElement.removeEventListener("mousemove",k),document.documentElement.removeEventListener("touchmove",k),document.documentElement.removeEventListener("mouseup",S),document.documentElement.removeEventListener("touchend",S)},I=()=>{if(!e.value||!t.value)return;let r=e.value.offsetLeft,i=e.value.offsetTop,g=e.value.offsetWidth,z=e.value.offsetHeight;r+g>window.innerWidth&&(r=window.innerWidth-g,r<0&&(r=0,g=window.innerWidth)),i+z>window.innerHeight&&(i=window.innerHeight-z,i<0&&(i=0,z=window.innerHeight)),e.value.style.left=`${r}px`,e.value.style.top=`${i}px`,e.value.style.width=`${g}px`,e.value.style.height=`${z}px`};return Ee(()=>{!e.value||!n||(typeof n.width=="number"&&(e.value.style.width=`${n.width}px`),typeof n.height=="number"&&(e.value.style.height=`${n.height}px`),typeof n.left=="number"&&(e.value.style.left=`${n.left}px`),typeof n.top=="number"&&(e.value.style.top=`${n.top}px`),I(),window.addEventListener("resize",I))}),$e(()=>{document.documentElement.removeEventListener("mousemove",$),document.documentElement.removeEventListener("touchmove",$),document.documentElement.removeEventListener("mouseup",M),document.documentElement.removeEventListener("touchend",M),document.documentElement.removeEventListener("mousemove",k),document.documentElement.removeEventListener("touchmove",k),document.documentElement.removeEventListener("mouseup",S),document.documentElement.removeEventListener("touchend",S),window.removeEventListener("resize",I)}),pe(()=>[e.value,t.value,l.value],([r,i,g])=>{r&&i&&(i.addEventListener("mousedown",H),i.addEventListener("touchstart",H)),r&&g&&(g.addEventListener("mousedown",j),g.addEventListener("touchstart",j))}),{handleResizeMouseDown:H,handleDragMouseDown:j}}const B=e=>(Ne("data-v-f572c9ca"),e=e(),We(),e),ft={class:"container"},vt={class:"action-bar"},mt=["title"],pt=["title"],gt={key:0,class:"icon",style:{cursor:"pointer"}},ht={key:0,"flex-placeholder":""},_t={key:1,class:"action-bar"},yt={key:0,class:"gen-info"},bt={class:"info-tags"},wt={class:"name"},Ot={class:"value"},Lt={key:0,class:"tags-container"},Et=["onClick"],$t=B(()=>y("br",null,null,-1)),kt=B(()=>y("h3",null,"Prompt",-1)),Mt=["innerHTML"],St=B(()=>y("br",null,null,-1)),Pt=B(()=>y("h3",null,"Negative Prompt",-1)),Ct=["innerHTML"],xt=B(()=>y("br",null,null,-1)),zt=B(()=>y("h3",null,"Params",-1)),Dt={style:{"font-weight":"600","text-transform":"capitalize"}},At={key:0},Tt={key:1},jt=["title"],It=ge({__name:"fullScreenContextMenu",props:{file:{},idx:{}},emits:["contextMenuClick"],setup(e,{emit:t}){const l=e,n=he(),o=ke(),b=X(),O=W(()=>o.tagMap.get(l.file.fullpath)??[]),L=X(""),C=Me(),E=X(""),x=W(()=>E.value.replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">").replace(/"/g,""").replace(/'/g,"'")),H=W(()=>x.value.split(`
|
|
`)),$=W(()=>le(x.value)),M=W(()=>{let a=le(x.value);return delete a.prompt,delete a.negativePrompt,a});function j(a){return`${a}`.replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">").replace(/"/g,'"').replace(/'/g,"'")}pe(()=>{var a;return(a=l==null?void 0:l.file)==null?void 0:a.fullpath},async a=>{a&&(C.tasks.forEach(u=>u.cancel()),C.pushAction(()=>Se(a)).res.then(u=>{E.value=u}))},{immediate:!0});const k=ae("iib@fullScreenContextMenu.prompt-tab","structedData"),S=X(),I=X(),r={left:100,top:100,width:512,height:384,expanded:!0},i=ae("fullScreenContextMenu.vue-drag",r);i.value&&(i.value.left<0||i.value.top<0)&&(i.value={...r}),dt(b,S,I,{...i.value,onDrag:re(function(a,u){i.value={...i.value,left:a,top:u}},300),onResize:re(function(a,u){i.value={...i.value,width:a,height:u}},300)});function g(a){return a.parentNode}function z(a){if(!a)return"";let u="";const N=a.split(/[\n,]+/).map(h=>h.trim()).filter(h=>h);let P=!1;for(let h=0;h<N.length;h++){const V=N[h];P||(P=V.includes("(")),u+=`<span class="${P?"has-parentheses":""}">${V}</span>`,h<N.length-1&&(u+=","),P&&(P=!V.includes(")"))}return u}Be("load",a=>{const u=a.target;u.className==="ant-image-preview-img"&&(L.value=`${u.naturalWidth} x ${u.naturalHeight}`)},{capture:!0});const ye=W(()=>{const a=[{name:A("fileName"),val:l.file.name},{name:A("fileSize"),val:l.file.size}];return L.value&&a.push({name:A("resolution"),val:L.value}),a}),be=()=>{const a="Negative prompt:",u=E.value.includes(a)?E.value.split(a)[0]:H.value[0]??"";ie(j(u.trim()))};return(a,u)=>{var ne;const N=Fe,P=G,h=De,V=Ae,ee=Te,we=G,te=je,Oe=Ie;return v(),p("div",{ref_key:"el",ref:b,class:se(["full-screen-menu",{"unset-size":!d(i).expanded}]),onWheelCapture:u[6]||(u[6]=ze(()=>{},["stop"]))},[y("div",ft,[y("div",vt,[y("div",{ref_key:"dragHandle",ref:I,class:"icon",style:{cursor:"grab"},title:d(A)("dragToMovePanel")},[s(d(Je))],8,mt),y("div",{class:"icon",style:{cursor:"pointer"},onClick:u[0]||(u[0]=m=>d(i).expanded=!d(i).expanded),title:d(A)("clickToToggleMaximizeMinimize")},[d(i).expanded?(v(),Y(d(et),{key:0})):(v(),Y(d(at),{key:1}))],8,pt),s(N,{"get-popup-container":g},{overlay:c(()=>[s(He,{file:a.file,idx:a.idx,"selected-tag":O.value,"disable-delete":d(oe)(a.file)===d(n).fullscreenPreviewInitialUrl,onContextMenuClick:u[1]||(u[1]=(m,D,Le)=>t("contextMenuClick",m,D,Le))},null,8,["file","idx","selected-tag","disable-delete"])]),default:c(()=>[d(i).expanded?w("",!0):(v(),p("div",gt,[s(d(Pe))]))]),_:1}),d(i).expanded?(v(),p("div",ht)):w("",!0),d(i).expanded?(v(),p("div",_t,[s(N,{trigger:["hover"],"get-popup-container":g},{overlay:c(()=>[s(ee,{onClick:u[2]||(u[2]=m=>t("contextMenuClick",m,a.file,a.idx))},{default:c(()=>{var m;return[((m=d(n).conf)==null?void 0:m.launch_mode)!=="server"?(v(),p(T,{key:0},[s(h,{key:"send2txt2img"},{default:c(()=>[_(f(a.$t("sendToTxt2img")),1)]),_:1}),s(h,{key:"send2img2img"},{default:c(()=>[_(f(a.$t("sendToImg2img")),1)]),_:1}),s(h,{key:"send2inpaint"},{default:c(()=>[_(f(a.$t("sendToInpaint")),1)]),_:1}),s(h,{key:"send2extras"},{default:c(()=>[_(f(a.$t("sendToExtraFeatures")),1)]),_:1}),s(V,{key:"sendToThirdPartyExtension",title:a.$t("sendToThirdPartyExtension")},{default:c(()=>[s(h,{key:"send2controlnet-txt2img"},{default:c(()=>[_("ControlNet - "+f(a.$t("t2i")),1)]),_:1}),s(h,{key:"send2controlnet-img2img"},{default:c(()=>[_("ControlNet - "+f(a.$t("i2i")),1)]),_:1}),s(h,{key:"send2outpaint"},{default:c(()=>[_("openOutpaint")]),_:1})]),_:1},8,["title"])],64)):w("",!0),s(h,{key:"send2BatchDownload"},{default:c(()=>[_(f(a.$t("sendToBatchDownload")),1)]),_:1}),s(h,{key:"send2savedDir"},{default:c(()=>[_(f(a.$t("send2savedDir")),1)]),_:1}),s(h,{key:"deleteFiles",disabled:d(oe)(a.file)===d(n).fullscreenPreviewInitialUrl},{default:c(()=>[_(f(a.$t("deleteSelected")),1)]),_:1},8,["disabled"]),s(h,{key:"previewInNewWindow"},{default:c(()=>[_(f(a.$t("previewInNewWindow")),1)]),_:1}),s(h,{key:"copyPreviewUrl"},{default:c(()=>[_(f(a.$t("copySourceFilePreviewLink")),1)]),_:1})]}),_:1})]),default:c(()=>[s(P,null,{default:c(()=>[_(f(d(A)("openContextMenu")),1)]),_:1})]),_:1}),s(we,{onClick:u[3]||(u[3]=m=>t("contextMenuClick",{key:"download"},l.file,l.idx))},{default:c(()=>[_(f(a.$t("download")),1)]),_:1}),E.value?(v(),Y(P,{key:0,onClick:u[4]||(u[4]=m=>d(ie)(E.value))},{default:c(()=>[_(f(a.$t("copyPrompt")),1)]),_:1})):w("",!0),E.value?(v(),Y(P,{key:1,onClick:be},{default:c(()=>[_(f(a.$t("copyPositivePrompt")),1)]),_:1})):w("",!0)])):w("",!0)]),d(i).expanded?(v(),p("div",yt,[y("div",bt,[(v(!0),p(T,null,U(ye.value,m=>(v(),p("span",{class:"info-tag",key:m.name},[y("span",wt,f(m.name),1),y("span",Ot,f(m.val),1)]))),128))]),(ne=d(n).conf)!=null&&ne.all_custom_tags?(v(),p("div",Lt,[(v(!0),p(T,null,U(d(n).conf.all_custom_tags,m=>(v(),p("div",{class:se(["tag",{selected:O.value.some(D=>D.id===m.id)}]),onClick:D=>t("contextMenuClick",{key:`toggle-tag-${m.id}`},a.file,a.idx),key:m.id,style:Ce({"--tag-color":d(o).getColor(m.name)})},f(m.name),15,Et))),128))])):w("",!0),s(Oe,{activeKey:d(k),"onUpdate:activeKey":u[5]||(u[5]=m=>xe(k)?k.value=m:null)},{default:c(()=>[s(te,{key:"structedData",tab:a.$t("structuredData")},{default:c(()=>[y("div",null,[$.value.prompt?(v(),p(T,{key:0},[$t,kt,y("code",{innerHTML:z($.value.prompt??"")},null,8,Mt)],64)):w("",!0),$.value.negativePrompt?(v(),p(T,{key:1},[St,Pt,y("code",{innerHTML:z($.value.negativePrompt??"")},null,8,Ct)],64)):w("",!0)]),Object.keys(M.value).length?(v(),p(T,{key:0},[xt,zt,y("table",null,[(v(!0),p(T,null,U(M.value,(m,D)=>(v(),p("tr",{key:D,class:"gen-info-frag"},[y("td",Dt,f(D),1),typeof m=="object"?(v(),p("td",At,[y("code",null,f(m),1)])):(v(),p("td",Tt,f(j(m)),1))]))),128))])],64)):w("",!0)]),_:1},8,["tab"]),s(te,{key:"sourceText",tab:a.$t("sourceText")},{default:c(()=>[y("code",null,f(E.value),1)]),_:1},8,["tab"])]),_:1},8,["activeKey"])])):w("",!0)]),d(i).expanded?(v(),p("div",{key:0,class:"mouse-sensor",ref_key:"resizeHandle",ref:S,title:d(A)("dragToResizePanel")},[s(d(Ue))],8,jt)):w("",!0)],34)}}});const qt=_e(It,[["__scopeId","data-v-f572c9ca"]]),Nt={key:0,class:"float-panel"},Wt={key:0,class:"select-actions"},Ft={key:1},Bt=ge({__name:"MultiSelectKeep",props:{show:{type:Boolean}},emits:["selectAll","reverseSelect","clearAllSelected"],setup(e,{emit:t}){const l=he(),n=()=>{t("clearAllSelected"),l.keepMultiSelect=!1},o=()=>{l.keepMultiSelect=!0};return(b,O)=>{const L=G;return b.show?(v(),p("div",Nt,[d(l).keepMultiSelect?(v(),p("div",Wt,[s(L,{size:"small",onClick:O[0]||(O[0]=C=>t("selectAll"))},{default:c(()=>[_(f(b.$t("select-all")),1)]),_:1}),s(L,{size:"small",onClick:O[1]||(O[1]=C=>t("reverseSelect"))},{default:c(()=>[_(f(b.$t("rerverse-select")),1)]),_:1}),s(L,{size:"small",onClick:O[2]||(O[2]=C=>t("clearAllSelected"))},{default:c(()=>[_(f(b.$t("clear-all-selected")),1)]),_:1}),s(L,{size:"small",onClick:n},{default:c(()=>[_(f(b.$t("exit")),1)]),_:1})])):(v(),p("div",Ft,[s(L,{size:"small",type:"primary",onClick:o},{default:c(()=>[_(f(b.$t("keep-multi-selected")),1)]),_:1})]))])):w("",!0)}}});const Qt=_e(Bt,[["__scopeId","data-v-b04c3508"]]);export{Ut as L,Qt as M,Gt as R,qt as f};
|