// @flow import updateState from "./update-state"; import {getConfig} from "./config"; import type {Config, Progression, State} from "./types"; declare export default function(progression: {actions: Array<{type: "init"} | {payload: {instructions: Array<{field: string, type: "add" | "set", value: number | boolean | string}> | null, nextContent: {ref: string, type: string, version?: string} | {ref: string, type: "video" | "pdf", version?: string}}, type: "move"} | {payload: {answer: Array, content: {ref: string, type: string, version?: string} | {ref: string, type: "video" | "pdf", version?: string}, godMode: ?boolean, instructions: Array<{field: string, type: "add" | "set", value: number | boolean | string}> | null, isCorrect: ?boolean, nextContent: {ref: string, type: string, version?: string} | {ref: string, type: "video" | "pdf", version?: string}}, type: "answer"} | {payload: {content: {ref: string, type: string, version?: string} | {ref: string, type: "video" | "pdf", version?: string}}, type: "clue"} | {payload: {content: {ref: string, type: string, version?: string} | {ref: string, type: "video" | "pdf", version?: string}, instructions: Array<{field: string, type: "add" | "set", value: number | boolean | string}> | null, nextContent: {ref: string, type: string, version?: string} | {ref: string, type: "video" | "pdf", version?: string}}, type: "extraLifeAccepted"} | {payload: {content: {ref: string, type: string, version?: string} | {ref: string, type: "video" | "pdf", version?: string}, nextContent: {ref: string, type: string, version?: string} | {ref: string, type: "video" | "pdf", version?: string}}, type: "extraLifeRefused"} | {payload: {content: {ref: string, type: string, version?: string} | {ref: string, type: "video" | "pdf", version?: string}, resource: {ref: string, type: "video" | "pdf", version?: string}}, type: "resource"} | {payload: {instructions: Array<{field: string, type: "add" | "set", value: number | boolean | string}> | null, nextContent: {ref: string, type: string, version?: string} | {ref: string, type: "video" | "pdf", version?: string}}, type: "move"}>, content: {ref: string, type: string, version?: string} | {ref: string, type: "video" | "pdf", version?: string}, engine: {ref: string, version: string}, engineOptions: {lives?: number, livesDisabled?: boolean}}): {content?: {ref: string, type: string, version?: string} | {ref: string, type: "video" | "pdf", version?: string}, nextContent: {ref: string, type: string, version?: string} | {ref: string, type: "video" | "pdf", version?: string}} & {allAnswers: Array<{answer: Array, isCorrect: ?boolean, slideRef: string}>, content?: {ref: string, type: string, version?: string} | {ref: string, type: "video" | "pdf", version?: string}, hasViewedAResourceAtThisStep: boolean, isCorrect: ?boolean, lives: number, livesDisabled?: boolean, nextContent?: {ref: string, type: string, version?: string} | {ref: string, type: "video" | "pdf", version?: string}, remainingLifeRequests: number, requestedClues: Array, slides: Array, stars: number, step: {current: number}, variables: {[_: string]: string | boolean | number}, viewedResources: Array<{ref: string, resources: Array, type: mixed /* UNEXPECTED TYPE: EvalT */}>};