import{d as V,aQ as S,D as l,e as i,E as s,g as L,z as M,U as k,I as o,f as h,H as m,b as u,B as c,$ as n,ab as C,_ as d}from"./lucide-BTN0wxUy.js";import{_ as T}from"./NowPlayingBadge.vue_vue_type_style_index_0_lang-DtlV-jz-.js";import{M as g,s as X,O as Y,L as p,T as z,S as A,G as O,_ as $}from"./index-D_5pVOyJ.js";import{M as D}from"./MediaItemThumb-DIXkdN25.js";import{_ as N}from"./ProviderIcon.vue_vue_type_style_index_0_lang-CPC7COBw.js";import{U as E,a as F,L as R,R as U,n as j,W as G,X as r,c as H}from"./vuetify-9bOe4YMy.js";const Q={class:"thumb-container"},W={style:{position:"absolute",left:"-10px",top:"0px","z-index":"2"}},q={key:1,class:"play-button-overlay"},J={key:0},K=V({__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:w}){const a=e,x=w,y=function(t){if(a.showCheckboxes)return;const b="clientX"in t?t.clientX:t.touches[0].clientX,f="clientY"in t?t.clientY:t.touches[0].clientY;A(a.item,b,f,a.parentItem)},B=function(t){if(a.showCheckboxes){x("select",a.item,!a.isSelected);return}z(a.item,t.clientX,t.clientY,a.parentItem)},I=function(t){a.showCheckboxes||O(a.item,t.clientX,t.clientY,a.parentItem)};return(t,b)=>{const f=S("hold");return i(),l(E,null,{default:s(({isHovering:v,props:P})=>[L((i(),l(F,M(P,{class:{"on-hover":v,unavailable:!e.isAvailable},elevation:"0",disabled:e.disabled,onClick:B,onContextmenu:k(y,["right","prevent"])}),{default:s(()=>[e.showCheckboxes?(i(),l(R,{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(U,{class:"panel-item-checkbox",ripple:!1,"model-value":e.isSelected},null,8,["model-value"])]),_:1},8,["model-value","scrim"])):o("",!0),h("div",Q,[m(D,{item:e.isAvailable?e.item:void 0},null,8,["item"]),h("div",W,[e.showProviderOnCover&&"provider_mappings"in e.item?(i(),l(N,{key:0,domain:e.item.media_type==c(g).PLAYLIST?e.item.provider_mappings[0].provider_domain:e.item.provider,size:20},null,8,["domain"])):o("",!0)]),e.isPlaying?(i(),l(T,{key:0,"icon-style":"position: absolute; right: 5px; bottom: 5px","show-badge":!1})):o("",!0),(v||c(X).isTouchscreen)&&e.isAvailable&&e.item.is_playable?(i(),u("div",q,[m(j,{icon:"mdi-play",color:"white",fab:"",style:{opacity:"0.6","font-size":"20px"},onClick:k(I,["stop"])})])):o("",!0)]),m(H,{variant:"text",slim:"",tile:"",density:"compact",class:"panel-item-details"},{default:s(()=>[m(G,null,{default:s(()=>[e.item.media_type==c(g).FOLDER?(i(),u("span",J,[h("span",null,n(c(Y)(e.item,t.$t)),1)])):(i(),u("span",{key:1,class:C({"is-playing":e.isPlaying})},n(e.item.name),3)),"version"in e.item&&e.item.version?(i(),u("span",{key:2,class:C({"is-playing":e.isPlaying})}," - "+n(e.item.version),3)):o("",!0)]),_:1}),"artists"in e.item&&e.item.artists?(i(),l(r,{key:0,class:"line-clamp-1"},{default:s(()=>[d(n(c(p)(e.item.artists,1)),1)]),_:1})):o("",!0),"authors"in e.item&&e.item.authors?(i(),l(r,{key:1,class:"line-clamp-1"},{default:s(()=>[d(n(e.item.authors.join(" / ")),1)]),_:1})):"publisher"in e.item&&e.item.publisher?(i(),l(r,{key:2,class:"line-clamp-1"},{default:s(()=>[d(n(e.item.publisher),1)]),_:1})):"owner"in e.item&&e.item.owner?(i(),l(r,{key:3,class:"line-clamp-1"},{default:s(()=>[d(n(e.item.owner),1)]),_:1})):"provider_mappings"in e.item?o("",!0):(i(),l(r,{key:4,class:"line-clamp-1"},{default:s(()=>[d(n(t.$t(e.item.media_type)),1)]),_:1}))]),_:1})]),_:2},1040,["class","disabled"])),[[f,y]])]),_:1})}}}),le=$(K,[["__scopeId","data-v-eba3a2ae"]]);export{le as P};
