ai-clip-factory / src /app /store /newChallenge.ts
jbilcke-hf's picture
jbilcke-hf HF staff
initial commit
9a42933
raw
history blame
333 Bytes
import { getRandomChallengeId } from "@/lib/getRandomChallengeId"
import { Challenge } from "@/types"
export function newChallenge(message: Partial<Challenge> = {}): Challenge {
return {
id: getRandomChallengeId(),
fromPlayer: "",
toPlayer: "",
assetUrl: "",
prompt: "",
solved: false,
...message
}
}