fix: 修复语法错误

This commit is contained in:
Reana 2025-01-22 08:20:10 +00:00
parent 68691c0e54
commit 3161a5ee27
2 changed files with 6 additions and 3 deletions

View File

@ -51,11 +51,11 @@ export default function VideoDetail({video, onClose,autoPlay}: Props) {
</div> </div>
<div className="flex justify-end modal-control-footer"> <div className="flex justify-end modal-control-footer">
<div className="flex gap-4"> <div className="flex gap-4">
<button disabled={state.pushing} className="text-gray-400 hover:text-gray-800 " type="text" onClick={pushToRoom}></button> <button disabled={state.pushing} className="text-gray-400 hover:text-gray-800 " type="button" onClick={pushToRoom}></button>
<button disabled={state.exporting} className="text-gray-400 hover:text-gray-800 " onClick={downloadVideo} <button disabled={state.exporting} className="text-gray-400 hover:text-gray-800 " onClick={downloadVideo}
type="text"> type="button">
</button> </button>
<button onClick={onClose} type="text" className="text-gray-800 hover:text-blue-500"></button> <button onClick={onClose} type="button" className="text-gray-800 hover:text-blue-500"></button>
</div> </div>
</div> </div>
</Modal> </Modal>

View File

@ -71,6 +71,7 @@ export default function LibraryIndex() {
autoPlay: boolean autoPlay: boolean
}>() }>()
const handleAllCheckedChange = (checked: boolean) => { const handleAllCheckedChange = (checked: boolean) => {
if (!data) return;
setCheckedIdArray(checked ? data.list.map(v => v.id) : []) setCheckedIdArray(checked ? data.list.map(v => v.id) : [])
setState({ setState({
checkedAll: !state.checkedAll checkedAll: !state.checkedAll
@ -158,6 +159,7 @@ export default function LibraryIndex() {
className='bg-gray-300 hover:bg-gray-400 text-white' className='bg-gray-300 hover:bg-gray-400 text-white'
icon={<IconDelete className=""/>} icon={<IconDelete className=""/>}
title={`你确定要删除选择的 ${checkedIdArray.length} 条视频吗?`} title={`你确定要删除选择的 ${checkedIdArray.length} 条视频吗?`}
emptyMessage={'请选择要删除的视频'}
confirmMessage={'删除后需重新生成视频'} confirmMessage={'删除后需重新生成视频'}
onProcess={deleteHistories} onProcess={deleteHistories}
></ButtonBatch>} ></ButtonBatch>}
@ -167,6 +169,7 @@ export default function LibraryIndex() {
className='bg-[#4096ff] hover:bg-blue-600 text-white' className='bg-[#4096ff] hover:bg-blue-600 text-white'
icon={<IconArrowRight className={'text-white'}/>} icon={<IconArrowRight className={'text-white'}/>}
onProcess={push2room} onProcess={push2room}
emptyMessage={'请选择要推流的视频'}
></ButtonBatch>} ></ButtonBatch>}
</div> </div>
</>) </>)