import{B as p,C as I,a1 as M,aC as S,aF as D,d as z,h as l,o as a,w as s,af as A,x as Y,aB as L,b1 as w,e as o,a as C,b as m,bm as O,c as y,z as T,u as c,M as x,s as X,V as H,k as N,t as n,bQ as $,n as B,bz as d,b5 as r,be as F,bS as E,bA as R,bR as j,bK as K}from"./index-Bn2Tzsay.js";import{V as Q,_ as q}from"./NowPlayingBadge.vue_vue_type_style_index_0_lang-DCLVCnPO.js";import{M as G}from"./MediaItemThumb-B7hfZSf2.js";import{V as J}from"./VBtn-BQk37KYJ.js";import{_ as U}from"./_plugin-vue_export-helper-DlAUqK2U.js";const W=I({disabled:Boolean,modelValue:{type:Boolean,default:null},...D()},"VHover"),Z=p()({name:"VHover",props:W(),emits:{"update:modelValue":e=>!0},setup(e,h){let{slots:i}=h;const u=M(e,"modelValue"),{runOpenDelay:f,runCloseDelay:b}=S(e,v=>!e.disabled&&(u.value=v));return()=>i.default?.({isHovering:u.value,props:{onMouseenter:f,onMouseleave:b}})}}),_={class:"thumb-container"},ee={style:{position:"absolute",left:"-10px",top:"0px","z-index":"2"}},te={key:1,class:"play-button-overlay"},ae={key:0},ie=z({__name:"PanelviewItemCompact",props:{item:{},size:{default:200},isSelected:{type:Boolean,default:!1},showCheckboxes:{type:Boolean,default:!1},permanentOverlay:{type:Boolean,default:!1},showProviderOnCover:{type:Boolean,default:!1},isAvailable:{type:Boolean,default:!0},isPlaying:{type:Boolean},parentItem:{default:void 0},disabled:{type:Boolean}},emits:["select"],setup(e,{emit:h}){const i=e,u=h,f=function(t){if(i.showCheckboxes)return;const V="clientX"in t?t.clientX:t.touches[0].clientX,k="clientY"in t?t.clientY:t.touches[0].clientY;j(i.item,V,k,i.parentItem)},b=function(t){if(i.showCheckboxes){u("select",i.item,!i.isSelected);return}E(i.item,t.clientX,t.clientY,i.parentItem)},v=function(t){i.showCheckboxes||K(i.item,t.clientX,t.clientY,i.parentItem)};return(t,V)=>{const k=R("hold");return a(),l(Z,null,{default:s(({isHovering:g,props:P})=>[A((a(),l(Y,L(P,{class:{"on-hover":g,unavailable:!e.isAvailable},elevation:"0",disabled:e.disabled,onClick:b,onContextmenu:w(f,["right","prevent"])}),{default:s(()=>[e.showCheckboxes?(a(),l(O,{key:0,"model-value":e.showCheckboxes,contained:"",scrim:e.isSelected?t.$vuetify.theme.current.dark?"rgba(0,0,0,.75)":"rgba(255,255,255,.75)":"#ffffff00"},{default:s(()=>[m(Q,{class:"panel-item-checkbox",ripple:!1,"model-value":e.isSelected},null,8,["model-value"])]),_:1},8,["model-value","scrim"])):o("",!0),C("div",_,[m(G,{item:e.isAvailable?e.item:void 0},null,8,["item"]),C("div",ee,[e.showProviderOnCover&&"provider_mappings"in e.item?(a(),l(T,{key:0,domain:e.item.media_type==c(x).PLAYLIST?e.item.provider_mappings[0].provider_domain:e.item.provider,size:20},null,8,["domain"])):o("",!0)]),e.isPlaying?(a(),l(q,{key:0,"icon-style":"position: absolute; right: 5px; bottom: 5px","show-badge":!1})):o("",!0),(g||c(X).isTouchscreen)&&e.isAvailable&&e.item.is_playable?(a(),y("div",te,[m(J,{icon:"mdi-play",color:"white",fab:"",style:{opacity:"0.6","font-size":"20px"},onClick:w(v,["stop"])})])):o("",!0)]),m(H,{variant:"text",slim:"",tile:"",density:"compact",class:"panel-item-details"},{default:s(()=>[m(N,null,{default:s(()=>[e.item.media_type==c(x).FOLDER?(a(),y("span",ae,[C("span",null,n(c($)(e.item,t.$t)),1)])):(a(),y("span",{key:1,class:B({"is-playing":e.isPlaying})},n(e.item.name),3)),"version"in e.item&&e.item.version?(a(),y("span",{key:2,class:B({"is-playing":e.isPlaying})}," - "+n(e.item.version),3)):o("",!0)]),_:1}),"artists"in e.item&&e.item.artists?(a(),l(d,{key:0,class:"line-clamp-1"},{default:s(()=>[r(n(c(F)(e.item.artists,1)),1)]),_:1})):o("",!0),"authors"in e.item&&e.item.authors?(a(),l(d,{key:1,class:"line-clamp-1"},{default:s(()=>[r(n(e.item.authors.join(" / ")),1)]),_:1})):"publisher"in e.item&&e.item.publisher?(a(),l(d,{key:2,class:"line-clamp-1"},{default:s(()=>[r(n(e.item.publisher),1)]),_:1})):"owner"in e.item&&e.item.owner?(a(),l(d,{key:3,class:"line-clamp-1"},{default:s(()=>[r(n(e.item.owner),1)]),_:1})):"provider_mappings"in e.item?o("",!0):(a(),l(d,{key:4,class:"line-clamp-1"},{default:s(()=>[r(n(t.$t(e.item.media_type)),1)]),_:1}))]),_:1})]),_:2},1040,["class","disabled"])),[[k,f]])]),_:1})}}}),ce=U(ie,[["__scopeId","data-v-eba3a2ae"]]);export{ce as P,Z as V};
