feat: 同步镜头首帧与视频生产工作区
This commit is contained in:
1 parent
669f4d9df0
commit
aeb3ce2986
16 files changed
+1802
-5
No files matched your search
@@ -0,0 +1,44 @@
|
||||
import type { ShotKeyframe, ShotVideo } from '../types'
|
||||
|
||||
/** 首帧测试记录,覆盖主图、候选与失败状态时只需覆写关心字段。 */
|
||||
export function keyframeFixture(patch: Partial<ShotKeyframe> = {}): ShotKeyframe {
|
||||
return {
|
||||
id: 'keyframe-1',
|
||||
shotId: 'shot-1',
|
||||
source: 'generated',
|
||||
provider: 'seedream',
|
||||
model: 'seedream-test',
|
||||
prompt: '首帧提示词',
|
||||
imageUrl: '/storage/keyframes/keyframe-1.png',
|
||||
width: 1920,
|
||||
height: 1080,
|
||||
status: 'completed',
|
||||
isPrimary: true,
|
||||
providerTaskId: null,
|
||||
error: null,
|
||||
createdAt: '2026-08-31T00:00:00.000Z',
|
||||
updatedAt: '2026-08-31T00:00:00.000Z',
|
||||
...patch
|
||||
}
|
||||
}
|
||||
|
||||
/** 视频测试记录,默认是已完成的主视频。 */
|
||||
export function videoFixture(patch: Partial<ShotVideo> = {}): ShotVideo {
|
||||
return {
|
||||
id: 'video-1',
|
||||
shotId: 'shot-1',
|
||||
provider: 'seedance',
|
||||
model: 'seedance-test',
|
||||
providerTaskId: 'provider-task-1',
|
||||
prompt: '视频提示词',
|
||||
negativePrompt: null,
|
||||
status: 'completed',
|
||||
videoUrl: '/storage/videos/video-1.mp4',
|
||||
durationSeconds: 5,
|
||||
isPrimary: true,
|
||||
error: null,
|
||||
createdAt: '2026-08-31T00:00:00.000Z',
|
||||
updatedAt: '2026-08-31T00:00:00.000Z',
|
||||
...patch
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user