Signed-off-by: Matt Bruce <mbrucedogs@gmail.com>
This commit is contained in:
parent
6e23b38636
commit
60b9fdc62e
@ -1,11 +1,11 @@
|
||||
vite.svg,499162500000,699a02e0e68a579f687d364bbbe7633161244f35af068220aee37b1b33dfb3c7
|
||||
index.html,1752951267549,fcd59ce73db356f2ef284a2837fd895a327871e97367e19e098f405eac038cd9
|
||||
assets/swipe-back-DodbPvvv.js,1752951267549,5a64d34a218e22a48662083486a8dbb1abe3ba6a7aef3eb38141b20375d32168
|
||||
assets/status-tap-D5L0hSFC.js,1752951267549,9d06b4e7a14b8ab895459b00442c3fca3c030f7252379e241a29da3a0939e3d0
|
||||
assets/md.transition-CB59U7UC.js,1752951267549,d1238422e9d3b5a091ffc130e49edbda08ff5a8c363827a2e83b6b4eba86d561
|
||||
assets/input-shims-DH-AIEE1.js,1752951267549,79595331808d1e1526a56470b4b1994a56f0b51e7c0bd7325d4268b4746f16d8
|
||||
assets/index7-CcY-smFt.js,1752951267549,8188642dc31ce6423f796e3bf2e3e3edfc362174042281a6a3a90b54f3119e98
|
||||
assets/ios.transition-k8m0vr45.js,1752951267549,532ed92f7f984e3043d6e04298089f106fff589d94046c041a0fa315b8f2a821
|
||||
assets/focus-visible-supuXXMI.js,1752951267549,df9266429356671847fa2c8123e1564bae645f75df3094f0055c365fa2beae28
|
||||
assets/index-DPys672b.css,1752951267548,c9c7d948a7ceefaff59d2530320f6139094e045985c18a068675d4fb76a70b7f
|
||||
assets/index-D8Qvd3dr.js,1752951267550,35fb31d66048c9cfa1d3aeee61d585e9a2617899eb6b85d179db4b0b00a5b42f
|
||||
index.html,1752951605613,3b193e76d96e2e703454d5fc53b1954151ddd57f6538ba62fdcbece720b6dd61
|
||||
assets/swipe-back-DMtim9hn.js,1752951605613,71353f9332d9e973fac6d43a2f028817d120295deff524e1e1807fa8d2049477
|
||||
assets/status-tap-WuGNn0YA.js,1752951605613,777d7cabd00c9519602ec5e3dcb2bd757a370a43ffd52d7d51ce4a886195ed29
|
||||
assets/md.transition-ClxjfWXF.js,1752951605613,a739784f987dc1fb17597abc73ca83ee9116ae3e6aab9893539370da414efbe2
|
||||
assets/input-shims-BPveaFSt.js,1752951605613,d3a570cd052e230f87c5c0902f68af08eb6c5920b8bf896d70101bccc4abccbb
|
||||
assets/ios.transition-BENZxPNL.js,1752951605613,bf5fb0825a54f61164be113cf6d3f33be57615cddc76b75742cc28385d6332f8
|
||||
assets/index7-1SPNlktY.js,1752951605613,238893fbf39dbf781502b1829d7e0d77baa505b5d0f918e73bb94e1dccee0fcc
|
||||
assets/focus-visible-supuXXMI.js,1752951605613,df9266429356671847fa2c8123e1564bae645f75df3094f0055c365fa2beae28
|
||||
assets/index-DPys672b.css,1752951605613,c9c7d948a7ceefaff59d2530320f6139094e045985c18a068675d4fb76a70b7f
|
||||
assets/index-CtEACmTC.js,1752951605614,3ccf47f5377df1aa3ec9069325bb5eddaf8eda45bbda0bf692f67a946f3a4489
|
||||
|
||||
@ -1,6 +1,15 @@
|
||||
{
|
||||
"controllers": {
|
||||
"mbrucedogs": {
|
||||
"disabledSongs":{
|
||||
"srhm9f": {
|
||||
"artist": "'Til Tuesday",
|
||||
"disabledAt": "2025-07-20T16:36:14.120Z",
|
||||
"key": "13651",
|
||||
"path": "z://MP4\\Let's Sing Karaoke\\'Til Tuesday - Voices Carry (Karaoke & Lyrics).mp4",
|
||||
"title": "Voices Carry"
|
||||
}
|
||||
},
|
||||
"favorites": [
|
||||
{
|
||||
"artist": "Michael Jackson",
|
||||
|
||||
@ -7,15 +7,7 @@ import { useDisabledSongs } from '../../hooks';
|
||||
import { InfiniteScrollList, ActionButton } from '../../components/common';
|
||||
import { filterSongs } from '../../utils/dataProcessing';
|
||||
import { setDebugEnabled, isDebugEnabled, debugLog } from '../../utils/logger';
|
||||
import type { Song } from '../../types';
|
||||
|
||||
interface DisabledSongDisplay {
|
||||
key?: string;
|
||||
path: string;
|
||||
artist: string;
|
||||
title: string;
|
||||
disabledAt: string;
|
||||
}
|
||||
import type { Song, DisabledSong } from '../../types';
|
||||
|
||||
const Settings: React.FC = () => {
|
||||
const isAdmin = useAppSelector(selectIsAdmin);
|
||||
@ -30,7 +22,7 @@ const Settings: React.FC = () => {
|
||||
const [searchTerm, setSearchTerm] = useState('');
|
||||
|
||||
// Convert disabled songs object to array for display
|
||||
const disabledSongsArray: DisabledSongDisplay[] = Object.entries(disabledSongs).map(([key, disabledSong]) => ({
|
||||
const disabledSongsArray: DisabledSong[] = Object.entries(disabledSongs).map(([key, disabledSong]) => ({
|
||||
key: disabledSong.key || key,
|
||||
path: disabledSong.path,
|
||||
artist: disabledSong.artist,
|
||||
@ -39,8 +31,8 @@ const Settings: React.FC = () => {
|
||||
}));
|
||||
|
||||
// Filter disabled songs by search term
|
||||
const filteredDisabledSongs: DisabledSongDisplay[] = searchTerm.trim()
|
||||
? filterSongs(disabledSongsArray, searchTerm) as DisabledSongDisplay[]
|
||||
const filteredDisabledSongs: DisabledSong[] = searchTerm.trim()
|
||||
? filterSongs(disabledSongsArray, searchTerm) as DisabledSong[]
|
||||
: disabledSongsArray;
|
||||
|
||||
const handleToggleSetting = async (setting: string, value: boolean) => {
|
||||
@ -52,7 +44,7 @@ const Settings: React.FC = () => {
|
||||
setDebugEnabled(enabled);
|
||||
};
|
||||
|
||||
const handleRemoveDisabledSong = async (song: DisabledSongDisplay) => {
|
||||
const handleRemoveDisabledSong = async (song: DisabledSong) => {
|
||||
// Create a minimal song object with the path for removal
|
||||
const songForRemoval: Song = {
|
||||
path: song.path,
|
||||
@ -163,7 +155,7 @@ const Settings: React.FC = () => {
|
||||
</div>
|
||||
|
||||
{/* Disabled Songs List */}
|
||||
<InfiniteScrollList<DisabledSongDisplay>
|
||||
<InfiniteScrollList<DisabledSong>
|
||||
items={filteredDisabledSongs}
|
||||
isLoading={loading}
|
||||
hasMore={false}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user