mirror of
https://github.com/muerwre/vault-frontend.git
synced 2025-04-25 12:56:41 +07:00
simple audio player
This commit is contained in:
parent
c11e281965
commit
5cad13b417
5 changed files with 70 additions and 9 deletions
|
@ -54,7 +54,14 @@ const Comment: FC<IProps> = ({ comment, is_empty, is_loading, className, photo,
|
|||
{groupped.audio && (
|
||||
<div className={styles.audios}>
|
||||
{groupped.audio.map(file => (
|
||||
<div key={file.id} onClick={() => Player.setSrc(getURL(file.url))}>
|
||||
<div
|
||||
key={file.id}
|
||||
onClick={() => {
|
||||
Player.set(getURL(file.url));
|
||||
Player.load();
|
||||
Player.play();
|
||||
}}
|
||||
>
|
||||
{file.name}
|
||||
</div>
|
||||
))}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue