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