diff --git a/packages/frontend/src/pages/LastFm.test.tsx b/packages/frontend/src/pages/LastFm.test.tsx index e25aa79bc..8ddfc6c81 100644 --- a/packages/frontend/src/pages/LastFm.test.tsx +++ b/packages/frontend/src/pages/LastFm.test.tsx @@ -23,7 +23,7 @@ describe('LastFmPage', () => { test('shows loading spinner initially', () => { vi.mocked(api.lastfm.status).mockReturnValue(new Promise(() => {})) renderPage() - expect(document.querySelector('.animate-spin')).toBeInTheDocument() + expect(document.querySelector('.animate-pulse')).toBeInTheDocument() }) test('shows not configured when lastfm is not set up', async () => { @@ -66,7 +66,7 @@ describe('LastFmPage', () => { expect(screen.getByText('Connect Your Account')).toBeInTheDocument() }) - expect(screen.getByText('Connect Last.fm')).toBeInTheDocument() + expect(screen.getByText('Connect with Last.fm')).toBeInTheDocument() }) test('shows error on fetch failure', async () => { diff --git a/packages/frontend/src/pages/LastFm.tsx b/packages/frontend/src/pages/LastFm.tsx index daa91c54b..fec23b0ae 100644 --- a/packages/frontend/src/pages/LastFm.tsx +++ b/packages/frontend/src/pages/LastFm.tsx @@ -1,8 +1,7 @@ import { useCallback, useEffect, useState } from 'react' -import { ExternalLink, Link2, Loader2, Music, Unlink } from 'lucide-react' +import { Check, ExternalLink, Link2, Loader2, Music, X } from 'lucide-react' import { api } from '@/services/api' import SectionHeader from '@/components/ui/SectionHeader' -import ActionPanel from '@/components/ui/ActionPanel' interface LastFmStatus { configured: boolean @@ -57,8 +56,18 @@ export default function LastFmPage() { if (isLoading) { return ( -
- +
+ } + /> +
+
+
+
+
) } @@ -73,51 +82,69 @@ export default function LastFmPage() { /> {error && ( -
- {error} +
+ +
+

+ {error} +

+
)} {!status?.configured ? ( -
-

Not Configured

-

- Last.fm integration is not configured on this bot. The server owner needs - to set - - LASTFM_API_KEY - - and - - LASTFM_API_SECRET - - . -

+
+
+
+ +
+
+

+ Not Configured +

+

+ Last.fm integration is not configured. Ask the server owner to set: +

+
+ + LASTFM_API_KEY + + + LASTFM_API_SECRET + +
+
+
) : status.linked ? ( -
-
- - - -
-

Connected

-

- Linked as +

+
+
+ +
+
+

+ Connected +

+

+ Linked as{' '} {status.username} - +

+
+ Active +
-

+

Tracks you request via the bot will be scrobbled to your Last.fm profile automatically.

@@ -125,66 +152,88 @@ export default function LastFmPage() {
) : ( -
-

Connect Your Account

-

- Link your Last.fm account so tracks you play through the bot are - automatically scrobbled to your profile. -

+
+
+

+ Connect Your Account +

+

+ Link your Last.fm account so tracks you play through the bot are + automatically scrobbled to your profile. +

+
+
)} -
- } - /> - } - /> +
+
+
+ +
+

+ Scrobble coverage +

+

+ Lucky tracks requested songs and forwards play activity once + linked. +

+
+
+
+ +
+
+ +
+

+ Privacy control +

+

+ Disconnect anytime without affecting server playback. +

+
+
+
-
-

How it works

-
    -
  • - 1. - Connect your Last.fm account above -
  • -
  • - 2. - Play music in a voice channel using the bot -
  • -
  • - 3. - Tracks are automatically scrobbled to your profile -
  • -
  • - 4. - External music bots (Rythm, Groovy, etc.) are also detected -
  • -
+
+

How it works

+
    + {[ + 'Connect your Last.fm account above', + 'Play music in a voice channel using the bot', + 'Tracks are automatically scrobbled to your profile', + 'External music bots (Rythm, Groovy, etc.) are also detected', + ].map((step, i) => ( +
  1. + + {i + 1} + + + {step} + +
  2. + ))} +
) diff --git a/packages/frontend/src/pages/Spotify.tsx b/packages/frontend/src/pages/Spotify.tsx index 90d92c031..51c433613 100644 --- a/packages/frontend/src/pages/Spotify.tsx +++ b/packages/frontend/src/pages/Spotify.tsx @@ -1,8 +1,7 @@ import { useCallback, useEffect, useState } from 'react' -import { ExternalLink, Link2, Loader2, Music, Unlink } from 'lucide-react' +import { Check, ExternalLink, Link2, Loader2, Music, X } from 'lucide-react' import { api } from '@/services/api' import SectionHeader from '@/components/ui/SectionHeader' -import ActionPanel from '@/components/ui/ActionPanel' interface SpotifyStatus { configured: boolean @@ -57,8 +56,18 @@ export default function SpotifyPage() { if (isLoading) { return ( -
- +
+ } + /> +
+
+
+
+
) } @@ -73,119 +82,157 @@ export default function SpotifyPage() { /> {error && ( -
- {error} +
+ +
+

+ {error} +

+
)} {!status?.configured ? ( -
-

Not Configured

-

- Spotify integration is not configured on this bot. The server owner needs - to set - - SPOTIFY_CLIENT_ID - - and - - SPOTIFY_CLIENT_SECRET - - . -

+
+
+
+ +
+
+

+ Not Configured +

+

+ Spotify integration is not configured. Ask the server owner to set: +

+
+ + SPOTIFY_CLIENT_ID + + + SPOTIFY_CLIENT_SECRET + +
+
+
) : status.linked ? ( -
-
- - - -
-

Connected

-

- Linked as +

+
+
+ +
+
+

+ Connected +

+

+ Linked as{' '} {status.username} - +

+
+ Active +
-

- Lucky can access your library and listening history to provide personalized - autoplay recommendations. +

+ Lucky can access your library and listening history to provide + personalized autoplay recommendations.

) : ( -
-

Connect Your Account

-

- Link your Spotify account so Lucky can learn your music preferences and - provide personalized autoplay recommendations. -

+
+
+

+ Connect Your Account +

+

+ Link your Spotify account so Lucky can learn your music preferences + and provide personalized autoplay recommendations. +

+
+
)} -
- } - /> - } - /> +
+
+
+ +
+

+ Smarter autoplay +

+

+ Lucky learns from your library, top tracks, and recent listening. +

+
+
+
+ +
+
+ +
+

+ Privacy control +

+

+ Disconnect anytime without affecting server playback. +

+
+
+
-
-

How it works

-
    -
  • - 1. - Connect your Spotify account above -
  • -
  • - 2. - Lucky accesses your library, top tracks, and recent listening -
  • -
  • - 3. - When autoplay is active, Lucky recommends similar tracks based on - your preferences -
  • -
  • - 4. - Your library stays private and is only used for recommendations -
  • -
+
+

How it works

+
    + {[ + 'Connect your Spotify account above', + 'Lucky accesses your library, top tracks, and recent listening', + 'When autoplay is active, Lucky recommends similar tracks based on your preferences', + 'Your library stays private and is only used for recommendations', + ].map((step, i) => ( +
  1. + + {i + 1} + + + {step} + +
  2. + ))} +
)