Separate Song component to own file instead of with queue

This commit is contained in:
2024-03-01 00:59:37 -05:00
committed by Ethan Girouard
parent bf47efbff7
commit 147e3c16c8
3 changed files with 16 additions and 13 deletions

14
src/song.rs Normal file
View File

@ -0,0 +1,14 @@
use leptos::*;
#[component]
pub fn Song(song_image_path: String, song_title: String, song_artist: String) -> impl IntoView {
view!{
<div class="queue-song">
<img src={song_image_path} alt={song_title.clone()} />
<div class="queue-song-info">
<h3>{song_title}</h3>
<p>{song_artist}</p>
</div>
</div>
}
}