sd-webui-infinite-image-bro.../vue/dist/assets/fullScreenContextMenu-2de1a...

3 lines
20 KiB
JavaScript

import{d as fe,bq as he,aI as ye,bW as be,ax as we,aC as X,bX as Oe,bY as K,e as R,c as o,_ as _e,h as C,a as ee,bz as Ee,P as te,ag as j,aw as Le,aM as $e,l as ve,k as Se,$ as T,ao as U,bO as xe,bZ as Pe,b_ as Ce,ai as A,o as h,y as b,p as N,r as u,m as I,n as p,L as ne,b$ as Me,C as M,z as B,x as y,v as g,t as ie,A as V,N as ae,B as ke,q as De,V as re,W as ze,c0 as Ae,M as Ne,X as je}from"./index-066a7869.js";import{i as Te,j as We,_ as Ie,D as Be}from"./FileItem-a96f33a2.js";import"./shortcut-16098eef.js";var Fe=["class","style"],Ue=function(){return{prefixCls:String,spinning:{type:Boolean,default:void 0},size:String,wrapperClassName:String,tip:te.any,delay:Number,indicator:te.any}},F=null;function Ve(t,e){return!!t&&!!e&&!isNaN(Number(e))}function kt(t){var e=t.indicator;F=typeof e=="function"?e:function(){return o(e,null,null)}}const Dt=fe({compatConfig:{MODE:3},name:"ASpin",inheritAttrs:!1,props:he(Ue(),{size:"default",spinning:!0,wrapperClassName:""}),setup:function(){return{originalUpdateSpinning:null,configProvider:ye("configProvider",be)}},data:function(){var e=this.spinning,i=this.delay,n=Ve(e,i);return{sSpinning:e&&!n}},created:function(){this.originalUpdateSpinning=this.updateSpinning,this.debouncifyUpdateSpinning(this.$props)},mounted:function(){this.updateSpinning()},updated:function(){var e=this;we(function(){e.debouncifyUpdateSpinning(),e.updateSpinning()})},beforeUnmount:function(){this.cancelExistingSpin()},methods:{debouncifyUpdateSpinning:function(e){var i=e||this.$props,n=i.delay;n&&(this.cancelExistingSpin(),this.updateSpinning=X(this.originalUpdateSpinning,n))},updateSpinning:function(){var e=this.spinning,i=this.sSpinning;i!==e&&(this.sSpinning=e)},cancelExistingSpin:function(){var e=this.updateSpinning;e&&e.cancel&&e.cancel()},renderIndicator:function(e){var i="".concat(e,"-dot"),n=Oe(this,"indicator");return n===null?null:(Array.isArray(n)&&(n=n.length===1?n[0]:n),K(n)?R(n,{class:i}):F&&K(F())?R(F(),{class:i}):o("span",{class:"".concat(i," ").concat(e,"-dot-spin")},[o("i",{class:"".concat(e,"-dot-item")},null),o("i",{class:"".concat(e,"-dot-item")},null),o("i",{class:"".concat(e,"-dot-item")},null),o("i",{class:"".concat(e,"-dot-item")},null)]))}},render:function(){var e,i,n,l=this.$props,w=l.size,_=l.prefixCls,$=l.tip,S=$===void 0?(e=(i=this.$slots).tip)===null||e===void 0?void 0:e.call(i):$,E=l.wrapperClassName,x=this.$attrs,P=x.class,k=x.style,O=_e(x,Fe),s=this.configProvider,D=s.getPrefixCls,L=s.direction,m=D("spin",_),r=this.sSpinning,a=(n={},C(n,m,!0),C(n,"".concat(m,"-sm"),w==="small"),C(n,"".concat(m,"-lg"),w==="large"),C(n,"".concat(m,"-spinning"),r),C(n,"".concat(m,"-show-text"),!!S),C(n,"".concat(m,"-rtl"),L==="rtl"),C(n,P,!!P),n),f=o("div",ee(ee({},O),{},{style:k,class:a}),[this.renderIndicator(m),S?o("div",{class:"".concat(m,"-text")},[S]):null]),c=Ee(this);if(c&&c.length){var d,z=(d={},C(d,"".concat(m,"-container"),!0),C(d,"".concat(m,"-blur"),r),d);return o("div",{class:["".concat(m,"-nested-loading"),E]},[r&&o("div",{key:"loading"},[f]),o("div",{class:z,key:"container"},[c])])}return f}});var Xe={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 Ye=Xe;function le(t){for(var e=1;e<arguments.length;e++){var i=arguments[e]!=null?Object(arguments[e]):{},n=Object.keys(i);typeof Object.getOwnPropertySymbols=="function"&&(n=n.concat(Object.getOwnPropertySymbols(i).filter(function(l){return Object.getOwnPropertyDescriptor(i,l).enumerable}))),n.forEach(function(l){He(t,l,i[l])})}return t}function He(t,e,i){return e in t?Object.defineProperty(t,e,{value:i,enumerable:!0,configurable:!0,writable:!0}):t[e]=i,t}var Y=function(e,i){var n=le({},e,i.attrs);return o(j,le({},n,{icon:Ye}),null)};Y.displayName="ArrowsAltOutlined";Y.inheritAttrs=!1;const qe=Y;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 oe(t){for(var e=1;e<arguments.length;e++){var i=arguments[e]!=null?Object(arguments[e]):{},n=Object.keys(i);typeof Object.getOwnPropertySymbols=="function"&&(n=n.concat(Object.getOwnPropertySymbols(i).filter(function(l){return Object.getOwnPropertyDescriptor(i,l).enumerable}))),n.forEach(function(l){Ze(t,l,i[l])})}return t}function Ze(t,e,i){return e in t?Object.defineProperty(t,e,{value:i,enumerable:!0,configurable:!0,writable:!0}):t[e]=i,t}var H=function(e,i){var n=oe({},e,i.attrs);return o(j,oe({},n,{icon:Qe}),null)};H.displayName="DragOutlined";H.inheritAttrs=!1;const Je=H;var Ke={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 Re=Ke;function se(t){for(var e=1;e<arguments.length;e++){var i=arguments[e]!=null?Object(arguments[e]):{},n=Object.keys(i);typeof Object.getOwnPropertySymbols=="function"&&(n=n.concat(Object.getOwnPropertySymbols(i).filter(function(l){return Object.getOwnPropertyDescriptor(i,l).enumerable}))),n.forEach(function(l){et(t,l,i[l])})}return t}function et(t,e,i){return e in t?Object.defineProperty(t,e,{value:i,enumerable:!0,configurable:!0,writable:!0}):t[e]=i,t}var q=function(e,i){var n=se({},e,i.attrs);return o(j,se({},n,{icon:Re}),null)};q.displayName="FullscreenExitOutlined";q.inheritAttrs=!1;const tt=q;var nt={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 it=nt;function ue(t){for(var e=1;e<arguments.length;e++){var i=arguments[e]!=null?Object(arguments[e]):{},n=Object.keys(i);typeof Object.getOwnPropertySymbols=="function"&&(n=n.concat(Object.getOwnPropertySymbols(i).filter(function(l){return Object.getOwnPropertyDescriptor(i,l).enumerable}))),n.forEach(function(l){at(t,l,i[l])})}return t}function at(t,e,i){return e in t?Object.defineProperty(t,e,{value:i,enumerable:!0,configurable:!0,writable:!0}):t[e]=i,t}var G=function(e,i){var n=ue({},e,i.attrs);return o(j,ue({},n,{icon:it}),null)};G.displayName="FullscreenOutlined";G.inheritAttrs=!1;const rt=G;var lt={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=lt;function ce(t){for(var e=1;e<arguments.length;e++){var i=arguments[e]!=null?Object(arguments[e]):{},n=Object.keys(i);typeof Object.getOwnPropertySymbols=="function"&&(n=n.concat(Object.getOwnPropertySymbols(i).filter(function(l){return Object.getOwnPropertyDescriptor(i,l).enumerable}))),n.forEach(function(l){st(t,l,i[l])})}return t}function st(t,e,i){return e in t?Object.defineProperty(t,e,{value:i,enumerable:!0,configurable:!0,writable:!0}):t[e]=i,t}var Q=function(e,i){var n=ce({},e,i.attrs);return o(j,ce({},n,{icon:ot}),null)};Q.displayName="LeftCircleOutlined";Q.inheritAttrs=!1;const zt=Q;var ut={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 ct=ut;function de(t){for(var e=1;e<arguments.length;e++){var i=arguments[e]!=null?Object(arguments[e]):{},n=Object.keys(i);typeof Object.getOwnPropertySymbols=="function"&&(n=n.concat(Object.getOwnPropertySymbols(i).filter(function(l){return Object.getOwnPropertyDescriptor(i,l).enumerable}))),n.forEach(function(l){dt(t,l,i[l])})}return t}function dt(t,e,i){return e in t?Object.defineProperty(t,e,{value:i,enumerable:!0,configurable:!0,writable:!0}):t[e]=i,t}var Z=function(e,i){var n=de({},e,i.attrs);return o(j,de({},n,{icon:ct}),null)};Z.displayName="RightCircleOutlined";Z.inheritAttrs=!1;const At=Z;function ft(t,e,i,n){const l={x:0,y:0};let w=0,_=0,$=typeof(n==null?void 0:n.width)=="number"?n.width:0,S=typeof(n==null?void 0:n.height)=="number"?n.height:0,E=typeof(n==null?void 0:n.left)=="number"?n.left:0,x=typeof(n==null?void 0:n.top)=="number"?n.top:0,P=!1;const k=a=>{a.stopPropagation(),a.preventDefault(),!(!t.value||!e.value)&&(w=a instanceof MouseEvent?a.clientX:a.touches[0].clientX,_=a instanceof MouseEvent?a.clientY:a.touches[0].clientY,$=t.value.offsetWidth,S=t.value.offsetHeight,l.x=e.value.offsetLeft,l.y=e.value.offsetTop,document.documentElement.addEventListener("mousemove",O),document.documentElement.addEventListener("touchmove",O),document.documentElement.addEventListener("mouseup",s),document.documentElement.addEventListener("touchend",s))},O=a=>{if(!t.value||!e.value)return;let f=$+((a instanceof MouseEvent?a.clientX:a.touches[0].clientX)-w),c=S+((a instanceof MouseEvent?a.clientY:a.touches[0].clientY)-_),d=l.x+((a instanceof MouseEvent?a.clientX:a.touches[0].clientX)-w),z=l.y+((a instanceof MouseEvent?a.clientY:a.touches[0].clientY)-_);d+e.value.offsetWidth>window.innerWidth&&(d=window.innerWidth-e.value.offsetWidth),t.value.offsetLeft+f>window.innerWidth&&(f=window.innerWidth-t.value.offsetLeft),z+e.value.offsetHeight>window.innerHeight&&(z=window.innerHeight-e.value.offsetHeight),t.value.offsetTop+c>window.innerHeight&&(c=window.innerHeight-t.value.offsetTop),t.value.style.width=`${f}px`,t.value.style.height=`${c}px`,e.value.style.left=`${d}px`,e.value.style.top=`${z}px`,n!=null&&n.onResize&&n.onResize(f,c)},s=()=>{document.documentElement.removeEventListener("mousemove",O),document.documentElement.removeEventListener("touchmove",O),document.documentElement.removeEventListener("mouseup",s),document.documentElement.removeEventListener("touchend",s)},D=a=>{a.stopPropagation(),a.preventDefault(),!(!t.value||!i.value)&&(P=!0,E=t.value.offsetLeft,x=t.value.offsetTop,w=a instanceof MouseEvent?a.clientX:a.touches[0].clientX,_=a instanceof MouseEvent?a.clientY:a.touches[0].clientY,document.documentElement.addEventListener("mousemove",L),document.documentElement.addEventListener("touchmove",L),document.documentElement.addEventListener("mouseup",m),document.documentElement.addEventListener("touchend",m))},L=a=>{if(!t.value||!i.value||!P)return;const f=E+((a instanceof MouseEvent?a.clientX:a.touches[0].clientX)-w),c=x+((a instanceof MouseEvent?a.clientY:a.touches[0].clientY)-_);f<0?t.value.style.left="0px":f+t.value.offsetWidth>window.innerWidth?t.value.style.left=`${window.innerWidth-t.value.offsetWidth}px`:t.value.style.left=`${f}px`,c<0?t.value.style.top="0px":c+t.value.offsetHeight>window.innerHeight?t.value.style.top=`${window.innerHeight-t.value.offsetHeight}px`:t.value.style.top=`${c}px`,n!=null&&n.onDrag&&n.onDrag(f,c)},m=()=>{P=!1,document.documentElement.removeEventListener("mousemove",L),document.documentElement.removeEventListener("touchmove",L),document.documentElement.removeEventListener("mouseup",m),document.documentElement.removeEventListener("touchend",m)},r=()=>{if(!t.value||!e.value)return;let a=t.value.offsetLeft,f=t.value.offsetTop,c=t.value.offsetWidth,d=t.value.offsetHeight;a+c>window.innerWidth&&(a=window.innerWidth-c,a<0&&(a=0,c=window.innerWidth)),f+d>window.innerHeight&&(f=window.innerHeight-d,f<0&&(f=0,d=window.innerHeight)),t.value.style.left=`${a}px`,t.value.style.top=`${f}px`,t.value.style.width=`${c}px`,t.value.style.height=`${d}px`};return Le(()=>{!t.value||!n||(typeof n.width=="number"&&(t.value.style.width=`${n.width}px`),typeof n.height=="number"&&(t.value.style.height=`${n.height}px`),typeof n.left=="number"&&(t.value.style.left=`${n.left}px`),typeof n.top=="number"&&(t.value.style.top=`${n.top}px`),r(),window.addEventListener("resize",r))}),$e(()=>{document.documentElement.removeEventListener("mousemove",O),document.documentElement.removeEventListener("touchmove",O),document.documentElement.removeEventListener("mouseup",s),document.documentElement.removeEventListener("touchend",s),document.documentElement.removeEventListener("mousemove",L),document.documentElement.removeEventListener("touchmove",L),document.documentElement.removeEventListener("mouseup",m),document.documentElement.removeEventListener("touchend",m),window.removeEventListener("resize",r)}),ve(()=>[t.value,e.value,i.value],([a,f,c])=>{a&&f&&(f.addEventListener("mousedown",k),f.addEventListener("touchstart",k)),a&&c&&(c.addEventListener("mousedown",D),c.addEventListener("touchstart",D))}),{handleResizeMouseDown:k,handleDragMouseDown:D}}const vt={class:"container"},pt={class:"action-bar"},mt=["title"],gt=["title"],ht={key:0,class:"icon",style:{cursor:"pointer"}},yt={key:0,"flex-placeholder":""},bt={key:1,class:"action-bar"},wt={key:0,class:"gen-info"},Ot={class:"info-tags"},_t={class:"name"},Et={class:"value"},Lt={key:0,class:"tags-container"},$t=["onClick"],St=["title"],xt=fe({__name:"fullScreenContextMenu",props:{file:{},idx:{}},emits:["contextMenuClick"],setup(t,{emit:e}){const i=t,n=Se(),l=Te(),w=T(),_=U(()=>l.tagMap.get(i.file.fullpath)??[]),$=T(""),S=xe(),E=T(""),x=U(()=>E.value.split(`
`));ve(()=>{var r;return(r=i==null?void 0:i.file)==null?void 0:r.fullpath},async r=>{r&&(S.tasks.forEach(a=>a.cancel()),S.pushAction(()=>Pe(r)).res.then(a=>{E.value=a}))},{immediate:!0});const P=T(),k=T(),O={left:100,top:100,width:512,height:384,expanded:!0},s=Ce("fullScreenContextMenu.vue-drag",O);s.value&&(s.value.left<0||s.value.top<0)&&(s.value={...O}),ft(w,P,k,{...s.value,onDrag:X(function(r,a){s.value={...s.value,left:r,top:a}},300),onResize:X(function(r,a){s.value={...s.value,width:r,height:a}},300)});function D(r){return r.parentNode}We("load",r=>{const a=r.target;a.className==="ant-image-preview-img"&&($.value=`${a.naturalWidth} x ${a.naturalHeight}`)},{capture:!0});const L=U(()=>{const r=[{name:A("fileName"),val:i.file.name},{name:A("fileSize"),val:i.file.size}];return $.value&&r.push({name:A("resolution"),val:$.value}),r}),m=()=>ie(x.value[0]??"");return(r,a)=>{var J;const f=Be,c=re,d=ze,z=Ae,pe=Ne,me=re;return h(),b("div",{ref_key:"el",ref:w,class:ae(["full-screen-menu",{"unset-size":!u(s).expanded}]),onWheelCapture:a[5]||(a[5]=De(()=>{},["stop"]))},[N("div",vt,[N("div",pt,[N("div",{ref_key:"dragHandle",ref:k,class:"icon",style:{cursor:"grab"},title:u(A)("dragToMovePanel")},[o(u(Je))],8,mt),N("div",{class:"icon",style:{cursor:"pointer"},onClick:a[0]||(a[0]=v=>u(s).expanded=!u(s).expanded),title:u(A)("clickToToggleMaximizeMinimize")},[u(s).expanded?(h(),I(u(tt),{key:0})):(h(),I(u(rt),{key:1}))],8,gt),o(f,{"get-popup-container":D},{overlay:p(()=>[o(Ie,{file:r.file,idx:r.idx,"selected-tag":_.value,"disable-delete":u(ne)(r.file)===u(n).fullscreenPreviewInitialUrl,onContextMenuClick:a[1]||(a[1]=(v,W,ge)=>e("contextMenuClick",v,W,ge))},null,8,["file","idx","selected-tag","disable-delete"])]),default:p(()=>[u(s).expanded?M("",!0):(h(),b("div",ht,[o(u(Me))]))]),_:1}),u(s).expanded?(h(),b("div",yt)):M("",!0),u(s).expanded?(h(),b("div",bt,[o(f,{trigger:["hover"],"get-popup-container":D},{overlay:p(()=>[o(pe,{onClick:a[2]||(a[2]=v=>e("contextMenuClick",v,r.file,r.idx))},{default:p(()=>{var v;return[((v=u(n).conf)==null?void 0:v.launch_mode)!=="server"?(h(),b(B,{key:0},[o(d,{key:"send2txt2img"},{default:p(()=>[y(g(r.$t("sendToTxt2img")),1)]),_:1}),o(d,{key:"send2img2img"},{default:p(()=>[y(g(r.$t("sendToImg2img")),1)]),_:1}),o(d,{key:"send2inpaint"},{default:p(()=>[y(g(r.$t("sendToInpaint")),1)]),_:1}),o(d,{key:"send2extras"},{default:p(()=>[y(g(r.$t("sendToExtraFeatures")),1)]),_:1}),o(z,{key:"sendToThirdPartyExtension",title:r.$t("sendToThirdPartyExtension")},{default:p(()=>[o(d,{key:"send2controlnet-txt2img"},{default:p(()=>[y("ControlNet - "+g(r.$t("t2i")),1)]),_:1}),o(d,{key:"send2controlnet-img2img"},{default:p(()=>[y("ControlNet - "+g(r.$t("i2i")),1)]),_:1}),o(d,{key:"send2outpaint"},{default:p(()=>[y("openOutpaint")]),_:1})]),_:1},8,["title"])],64)):M("",!0),o(d,{key:"send2BatchDownload"},{default:p(()=>[y(g(r.$t("sendToBatchDownload")),1)]),_:1}),o(d,{key:"send2savedDir"},{default:p(()=>[y(g(r.$t("send2savedDir")),1)]),_:1}),o(d,{key:"deleteFiles",disabled:u(ne)(r.file)===u(n).fullscreenPreviewInitialUrl},{default:p(()=>[y(g(r.$t("deleteSelected")),1)]),_:1},8,["disabled"]),o(d,{key:"previewInNewWindow"},{default:p(()=>[y(g(r.$t("previewInNewWindow")),1)]),_:1}),o(d,{key:"copyPreviewUrl"},{default:p(()=>[y(g(r.$t("copySourceFilePreviewLink")),1)]),_:1})]}),_:1})]),default:p(()=>[o(c,null,{default:p(()=>[y(g(u(A)("openContextMenu")),1)]),_:1})]),_:1}),o(me,{onClick:a[3]||(a[3]=v=>e("contextMenuClick",{key:"download"},i.file,i.idx))},{default:p(()=>[y(g(r.$t("download")),1)]),_:1}),E.value?(h(),I(c,{key:0,onClick:a[4]||(a[4]=v=>u(ie)(E.value))},{default:p(()=>[y(g(r.$t("copyPrompt")),1)]),_:1})):M("",!0),E.value?(h(),I(c,{key:1,onClick:m},{default:p(()=>[y(g(r.$t("copyPositivePrompt")),1)]),_:1})):M("",!0)])):M("",!0)]),u(s).expanded?(h(),b("div",wt,[N("div",Ot,[(h(!0),b(B,null,V(L.value,v=>(h(),b("span",{class:"info-tag",key:v.name},[N("span",_t,g(v.name),1),N("span",Et,g(v.val),1)]))),128))]),(J=u(n).conf)!=null&&J.all_custom_tags?(h(),b("div",Lt,[(h(!0),b(B,null,V(u(n).conf.all_custom_tags,v=>(h(),b("div",{class:ae(["tag",{selected:_.value.some(W=>W.id===v.id)}]),onClick:W=>e("contextMenuClick",{key:`toggle-tag-${v.id}`},r.file,r.idx),key:v.id,style:ke({"--tag-color":u(l).getColor(v.name)})},g(v.name),15,$t))),128))])):M("",!0),(h(!0),b(B,null,V(x.value,v=>(h(),b("p",{key:v,class:"gen-info-frag"},g(v),1))),128))])):M("",!0)]),u(s).expanded?(h(),b("div",{key:0,class:"mouse-sensor",ref_key:"resizeHandle",ref:P,title:u(A)("dragToResizePanel")},[o(u(qe))],8,St)):M("",!0)],34)}}});const Nt=je(xt,[["__scopeId","data-v-3ba1b3cd"]]);export{zt as L,At as R,Dt as S,Nt as f,kt as s};