mirror of
https://github.com/antebudimir/feishin.git
synced 2026-01-02 02:43:33 +00:00
Adjust lyrics styling / animations
This commit is contained in:
parent
7cd2077dcd
commit
5dd860735d
5 changed files with 47 additions and 28 deletions
|
|
@ -1,17 +1,20 @@
|
|||
import { useMemo } from 'react';
|
||||
import { Text } from '/@/renderer/components';
|
||||
import { LyricLine } from '/@/renderer/features/lyrics/lyric-line';
|
||||
|
||||
interface UnsynchronizedLyricsProps {
|
||||
lyrics: string;
|
||||
source: string | null;
|
||||
}
|
||||
|
||||
export const UnsynchronizedLyrics = ({ lyrics }: UnsynchronizedLyricsProps) => {
|
||||
export const UnsynchronizedLyrics = ({ lyrics, source }: UnsynchronizedLyricsProps) => {
|
||||
const lines = useMemo(() => {
|
||||
return lyrics.split('\n');
|
||||
}, [lyrics]);
|
||||
|
||||
return (
|
||||
<div>
|
||||
<div className="unsynchronized-lyrics">
|
||||
{source && <Text $noSelect>Lyrics provided by: {source}</Text>}
|
||||
{lines.map((text, idx) => (
|
||||
<LyricLine
|
||||
key={idx}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue