Skip to content

Commit

Permalink
Remove duplicated interfaces
Browse files Browse the repository at this point in the history
  • Loading branch information
brentvollebregt committed Jan 18, 2024
1 parent 7ef2208 commit a3cf92c
Showing 1 changed file with 1 addition and 14 deletions.
15 changes: 1 addition & 14 deletions client/src/hooks/useLyrics.ts
Original file line number Diff line number Diff line change
@@ -1,20 +1,7 @@
import { useEffect, useState } from "react";
import { ILRCContent } from "../../../src/dto";
import { getLyrics } from "../api";
import { CurrentlyPlayingState, PlayingStates } from "../types/currentlyPlayingState";

interface ILyricDetails {
content: string;
artist: string;
title: string;
syncedLyricsArray?: Array<ILRCContent>;
lyricsSourceReference?: string;
}

interface ITrackLyrics {
currentlyPlayingItemId: string;
lyrics: ILyricDetails | undefined;
}
import { ITrackLyrics } from "../types/trackLyrics";

const useLyrics = (currentlyPlaying: CurrentlyPlayingState) => {
const [lyrics, setLyrics] = useState<ITrackLyrics | undefined>(undefined); // undefined = no lyrics yet, .lyrics=undefined = no lyrics exist
Expand Down

0 comments on commit a3cf92c

Please sign in to comment.