mirror of
https://github.com/owntone/owntone-server.git
synced 2025-01-01 01:53:23 -05:00
2 lines
242 KiB
JavaScript
2 lines
242 KiB
JavaScript
|
import{c as Ys,o as l,a as _,b as t,r as O,d as y,n as C,e as v,t as m,S as F,f as u,w as d,g as $,T as N,h as D,i as U,v as M,j as Qs,k as h,l as w,s as Js,m as Zt,P as Xt,p as B,F as T,q as I,u as Q,x as ts,y as J,z as bs,A as zt,B as Vt,C as ss,D as Zs,E as Xs,G as te,H as Y,I as se,R as ee,J as ie,K as oe,V as ae,L as ne,M as le,N as re}from"./vendor.js";const de=function(){const e=document.createElement("link").relList;if(e&&e.supports&&e.supports("modulepreload"))return;for(const o of document.querySelectorAll('link[rel="modulepreload"]'))r(o);new MutationObserver(o=>{for(const i of o)if(i.type==="childList")for(const n of i.addedNodes)n.tagName==="LINK"&&n.rel==="modulepreload"&&r(n)}).observe(document,{childList:!0,subtree:!0});function a(o){const i={};return o.integrity&&(i.integrity=o.integrity),o.referrerpolicy&&(i.referrerPolicy=o.referrerpolicy),o.crossorigin==="use-credentials"?i.credentials="include":o.crossorigin==="anonymous"?i.credentials="omit":i.credentials="same-origin",i}function r(o){if(o.ep)return;o.ep=!0;const i=a(o);fetch(o.href,i)}};de();const ks="UPDATE_CONFIG",ws="UPDATE_SETTINGS",Bt="UPDATE_SETTINGS_OPTION",vs="UPDATE_LIBRARY_STATS",$s="UPDATE_LIBRARY_AUDIOBOOKS_COUNT",xs="UPDATE_LIBRARY_PODCASTS_COUNT",Cs="UPDATE_LIBRARY_RSS_COUNT",qs="UPDATE_OUTPUTS",es="UPDATE_PLAYER_STATUS",Ss="UPDATE_QUEUE",Ps="UPDATE_LASTFM",As="UPDATE_SPOTIFY",Ts="UPDATE_PAIRING",is="SPOTIFY_NEW_RELEASES",os="SPOTIFY_FEATURED_PLAYLISTS",gs="ADD_NOTIFICATION",Wt="DELETE_NOTIFICATION",Yt="SEARCH_PATH",as="ADD_RECENT_SEARCH",Mt="HIDE_SINGLES",ns="HIDE_SPOTIFY",Rs="ARTISTS_SORT",Es="ARTIST_ALBUMS_SORT",Is="ALBUMS_SORT",Us="SHOW_ONLY_NEXT_ITEMS",Z="SHOW_BURGER_MENU",X="SHOW_PLAYER_MENU",ot="SHOW_UPDATE_DIALOG",ls="UPDATE_DIALOG_SCAN_KIND";var A=Ys({state(){return{config:{websocket_port:0,version:"",buildoptions:[]},settings:{categories:[]},library:{artists:0,albums:0,songs:0,db_playtime:0,updating:!1},audiobooks_count:{},podcasts_count:{},rss_count:{},outputs:[],player:{state:"stop",repeat:"off",consume:!1,shuffle:!1,volume:0,item_id:0,item_length_ms:0,item_progress_ms:0},queue:{version:0,count:0,items:[]},lastfm:{},spotify:{},pairing:{},spotify_new_releases:[],spotify_featured_playlists:[],notifications:{next_id:1,list:[]},search_path:"/search/library",recent_searches:[],hide_singles:!1,hide_spotify:!1,artists_sort:"Name",artist_albums_sort:"Name",albums_sort:"Name",show_only_next_items:!1,show_burger_menu:!1,show_player_menu:!1,show_update_dialog:!1,update_dialog_scan_kind:""}},getters:{now_playing:s=>{const e=s.queue.items.find(function(a){return a.id===s.player.item_id});return e===void 0?{}:e},settings_webinterface:s=>s.settings?s.settings.categories.find(e=>e.name==="webinterface"):null,settings_option_recently_added_limit:(s,e)=>{if(e.settings_webinterface){const a=e.settings_webinterface.options.find(r=>r.name==="recently_added_limit");if(a)return a.value}return 100},settings_option_show_composer_now_playing:(s,e)=>{if(e.settings_webinterface){const a=e.settings_webinterface.options.find(r=>r.name==="show_composer_now_playing");if(a)return a.value}return!1},settings_option_show_composer_for_genre:(s,e)=>{if(e.settings_webinterface){const a=e.settings_webinterface.options.find(r=>r.name==="show_composer_for_genre");if(a)return a.value}return null},settings_category:s=>e=>s.settings.categories.find(a=>a.name===e),settings_option:s=>(e,a)=>{const r=s.settings.categories.find(o=>o.name===e);return r?r.options.find(o=>o.name===a):{}}},mutations:{[ks](s,e){s.config=e},[ws](s,e){s.settings=e},[Bt](s,e){const r=s.settings.categories.find(o=>o.name===e.category).options.find(o=>o.name===e.name);r.value=e.value},[vs](s,e){s.library=e},[$s](s,e){s.audiobooks_count=e},[xs](s,e){s.podcasts_count=e},[Cs](s,e){s.rss_count=e},[qs](s,e){s.outputs=e},[es](s,e){s.player=e},[Ss](s,e){s.queue=e},[Ps](s,e){s.lastfm=e},[As](s,e){s.spotify=e},[Ts](s,e){s.pairing=e},[is](s,e){s.spotify_new_releases=e},[os](s,e){s.spotify_featured_playlists=e},[gs](s,e){if(e.topic){const a=s.notifications.list.findIndex(r=>r.topic===e.topic);if(a>=0){s.not
|