This commit is contained in:
root 2025-07-11 17:59:20 +08:00
parent 51bc52118d
commit 5a90495561
2 changed files with 2 additions and 2 deletions

View File

@ -25,7 +25,7 @@
}
],
"security": {
"csp": "default-src 'self'; img-src 'self' asset: data: http://asset.localhost; script-src 'self' 'unsafe-inline'; style-src 'self' 'unsafe-inline'; connect-src 'self' ipc: http://ipc.localhost",
"csp": "default-src 'self'; img-src 'self' asset: data: http://asset.localhost; media-src 'self' asset: http://asset.localhost; video-src 'self' asset: http://asset.localhost; script-src 'self' 'unsafe-inline'; style-src 'self' 'unsafe-inline'; connect-src 'self' ipc: http://ipc.localhost",
"assetProtocol": {
"enable": true,
"scope": [

View File

@ -59,7 +59,7 @@ const VideoPlayer: React.FC<VideoPlayerProps> = ({
// 尝试多种方法加载视频
const tryLoadVideo = async (path: string) => {
// 根据路径类型选择不同的加载策略
const src = convertFileSrc(path, 'file')
const src = convertFileSrc(path)
console.log(`try load video src`, src)
setVideoSrc(src)
setLoadingMethod('convertFileSrc')