2025-12-09 22:28:25 +01:00
import { storage } from "@vendetta/plugin" ;
import { useProxy } from "@vendetta/storage" ;
2026-07-19 17:17:13 +02:00
import { React } from "@vendetta/metro/common" ;
import {
ScrollView ,
Stack ,
TableRowGroup ,
TableRow ,
TableSwitchRow ,
} from "../components/TableComponents" ;
2025-12-09 22:28:25 +01:00
export default function SpotifySettingsPage() {
2026-05-09 10:20:55 +02:00
useProxy ( storage ) ;
const [ , forceUpdate ] = React . useReducer ( ( x ) = > x + 1 , 0 ) ;
2025-12-09 22:28:25 +01:00
2026-05-09 10:20:55 +02:00
return (
2026-07-19 17:17:13 +02:00
< ScrollView style = { { flex : 1 } } contentContainerStyle = { { padding : 10 } } >
< Stack spacing = { 12 } >
< TableRowGroup title = "Spotify Commands" >
< TableSwitchRow
label = "/spotify track"
subLabel = "Share your current Spotify track"
value = { storage . enabledCommands . spotifyTrack }
onValueChange = { ( v ) = > {
storage . enabledCommands . spotifyTrack = v ;
storage . pendingRestart = true ;
forceUpdate ( ) ;
} }
/ >
< TableSwitchRow
label = "/spotify album"
subLabel = "Share your current track's album"
value = { storage . enabledCommands . spotifyAlbum }
onValueChange = { ( v ) = > {
storage . enabledCommands . spotifyAlbum = v ;
storage . pendingRestart = true ;
forceUpdate ( ) ;
} }
/ >
< TableSwitchRow
label = "/spotify artists"
subLabel = "Share your current track's artists"
value = { storage . enabledCommands . spotifyArtists }
onValueChange = { ( v ) = > {
storage . enabledCommands . spotifyArtists = v ;
storage . pendingRestart = true ;
forceUpdate ( ) ;
} }
/ >
< TableSwitchRow
label = "/spotify cover"
subLabel = "Share your current track's cover"
value = { storage . enabledCommands . spotifyCover }
onValueChange = { ( v ) = > {
storage . enabledCommands . spotifyCover = v ;
storage . pendingRestart = true ;
forceUpdate ( ) ;
} }
/ >
< / TableRowGroup >
2025-12-09 22:28:25 +01:00
2026-07-19 17:17:13 +02:00
< TableRowGroup title = "About Spotify Commands" >
< TableRow
label = "Spotify Integration"
subLabel = "These commands allow you to share your current Spotify activity in Discord. Make sure you have Spotify connected to Discord for these commands to work properly."
/ >
< / TableRowGroup >
< / Stack >
< / ScrollView >
2026-05-09 10:20:55 +02:00
) ;
2025-12-09 22:28:25 +01:00
}