From a0a77855ec546109971c83118a0c9b519e69bedb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Gy=C3=B6rgy=20Bal=C3=A1ssy?= Date: Fri, 17 Jan 2014 12:45:01 +0100 Subject: [PATCH] Support multiple 'from' states According to https://github.com/jakesgordon/javascript-state-machine: "If an event is allowed from multiple states, and always transitions to the same state, then simply provide an array of states in the from attribute of an event." So the from property can be of type string or string[], so "any" is required here. --- state-machine/state-machine.d.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/state-machine/state-machine.d.ts b/state-machine/state-machine.d.ts index efecb2e4c3..3415beb7c8 100644 --- a/state-machine/state-machine.d.ts +++ b/state-machine/state-machine.d.ts @@ -11,7 +11,7 @@ interface StateMachineErrorCallback { interface StateMachineEventDef { name: string; - from: string; + from: any; // string or string[] to: string; } @@ -78,4 +78,4 @@ interface StateMachine { transition: StateMachineTransition; } -declare var StateMachine: StateMachineStatic; \ No newline at end of file +declare var StateMachine: StateMachineStatic;