diff --git a/src/frontend/src/app/app.component.html b/src/frontend/src/app/app.component.html
index 0bf2ba7..97d2ea3 100644
--- a/src/frontend/src/app/app.component.html
+++ b/src/frontend/src/app/app.component.html
@@ -13,15 +13,22 @@
Download
-
-
-
+
+
+
+
+
+
Please enter a valid Spotify URL (e.g. https://open.spotify.com/...)
diff --git a/src/frontend/src/app/app.component.ts b/src/frontend/src/app/app.component.ts
index 2370615..cd72f00 100644
--- a/src/frontend/src/app/app.component.ts
+++ b/src/frontend/src/app/app.component.ts
@@ -16,6 +16,11 @@ import {map} from "rxjs";
export class AppComponent {
url = ''
+ private readonly spotifyUrlPattern = /^https:\/\/open\.spotify\.com\/(track|playlist|album|artist)\/[a-zA-Z0-9]+/;
+
+ get isValidSpotifyUrl(): boolean {
+ return this.spotifyUrlPattern.test(this.url);
+ }
createLoading$ = this.playlistService.createLoading$;
playlists$ = this.playlistService.all$.pipe(map(items => items.filter(item => !item.isTrack)));
songs$ = this.playlistService.all$.pipe(map(items => items.filter(item => item.isTrack)));