mirror of
https://github.com/langgenius/dify.git
synced 2025-12-21 10:15:33 -05:00
Co-authored-by: crazywoola <100913391+crazywoola@users.noreply.github.com> Co-authored-by: johnny0120 <johnny0120@users.noreply.github.com> Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com> Co-authored-by: Wood <tuiskuwood@outlook.com>
20 lines
378 B
TypeScript
20 lines
378 B
TypeScript
import React from 'react'
|
|
import AudioPlayer from './AudioPlayer'
|
|
|
|
type Props = {
|
|
srcs: string[]
|
|
}
|
|
|
|
const AudioGallery: React.FC<Props> = ({ srcs }) => {
|
|
const validSrcs = srcs.filter(src => src)
|
|
if (validSrcs.length === 0) return null
|
|
|
|
return (
|
|
<div className="my-3">
|
|
<AudioPlayer srcs={validSrcs} />
|
|
</div>
|
|
)
|
|
}
|
|
|
|
export default React.memo(AudioGallery)
|