xstate 5.0.0-beta.7 → 5.0.0-beta.8

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (32) hide show
  1. package/actions/dist/xstate-actions.cjs.dev.js +2 -1
  2. package/actions/dist/xstate-actions.cjs.prod.js +2 -1
  3. package/actions/dist/xstate-actions.esm.js +1 -1
  4. package/actions/dist/xstate-actions.umd.min.js +1 -1
  5. package/actions/dist/xstate-actions.umd.min.js.map +1 -1
  6. package/actors/dist/xstate-actors.cjs.dev.js +2 -1
  7. package/actors/dist/xstate-actors.cjs.prod.js +2 -1
  8. package/actors/dist/xstate-actors.esm.js +1 -1
  9. package/actors/dist/xstate-actors.umd.min.js +1 -1
  10. package/actors/dist/xstate-actors.umd.min.js.map +1 -1
  11. package/dist/{actions-a1a641d3.cjs.prod.js → actions-900f9761.cjs.prod.js} +94 -49
  12. package/dist/{actions-b334e916.esm.js → actions-c8d7df32.esm.js} +93 -48
  13. package/dist/{actions-0fcf4fd9.cjs.dev.js → actions-d06ca158.cjs.dev.js} +94 -49
  14. package/dist/declarations/src/StateMachine.d.ts +2 -2
  15. package/dist/declarations/src/actions.d.ts +1 -0
  16. package/dist/declarations/src/actors/index.d.ts +2 -1
  17. package/dist/declarations/src/actors/observable.d.ts +1 -2
  18. package/dist/declarations/src/actors/promise.d.ts +1 -2
  19. package/dist/declarations/src/index.d.ts +12 -28
  20. package/dist/declarations/src/types.d.ts +3 -3
  21. package/dist/declarations/src/waitFor.d.ts +33 -0
  22. package/dist/xstate.cjs.dev.js +85 -50
  23. package/dist/xstate.cjs.prod.js +82 -50
  24. package/dist/xstate.esm.js +71 -48
  25. package/dist/xstate.umd.min.js +1 -1
  26. package/dist/xstate.umd.min.js.map +1 -1
  27. package/guards/dist/xstate-guards.cjs.dev.js +1 -1
  28. package/guards/dist/xstate-guards.cjs.prod.js +1 -1
  29. package/guards/dist/xstate-guards.esm.js +1 -1
  30. package/guards/dist/xstate-guards.umd.min.js.map +1 -1
  31. package/package.json +1 -1
  32. package/dist/declarations/src/schema.d.ts +0 -2
@@ -519,6 +519,9 @@ function send$1(eventOrExpr, options) {
519
519
  var delaysMap = state.machine.options.delays;
520
520
 
521
521
  // TODO: helper function for resolving Expr
522
+ if (typeof eventOrExpr === 'string') {
523
+ throw new Error("Only event objects may be used with sendTo; use sendTo({ type: \"".concat(eventOrExpr, "\" }) instead"));
524
+ }
522
525
  var resolvedEvent = toSCXMLEvent(isFunction(eventOrExpr) ? eventOrExpr(args) : eventOrExpr);
523
526
  var resolvedDelay;
524
527
  if (isString(params.delay)) {
@@ -816,25 +819,28 @@ promiseCreator) {
816
819
  var behavior = {
817
820
  transition: function transition(state, event) {
818
821
  var _event = toSCXMLEvent(event);
819
- if (state.canceled) {
822
+ if (state.status !== 'active') {
820
823
  return state;
821
824
  }
822
825
  var eventObject = _event.data;
823
826
  switch (_event.name) {
824
827
  case resolveEventType:
825
- state.status = 'done';
826
- state.data = eventObject.data;
827
- delete state.input;
828
- return state;
828
+ return _objectSpread2(_objectSpread2({}, state), {}, {
829
+ status: 'done',
830
+ data: eventObject.data,
831
+ input: undefined
832
+ });
829
833
  case rejectEventType:
830
- state.status = 'error';
831
- state.data = eventObject.data;
832
- delete state.input;
833
- return state;
834
+ return _objectSpread2(_objectSpread2({}, state), {}, {
835
+ status: 'error',
836
+ data: eventObject.data,
837
+ input: undefined
838
+ });
834
839
  case stopSignalType:
835
- state.canceled = true;
836
- delete state.input;
837
- return state;
840
+ return _objectSpread2(_objectSpread2({}, state), {}, {
841
+ status: 'canceled',
842
+ input: undefined
843
+ });
838
844
  default:
839
845
  return state;
840
846
  }
@@ -863,7 +869,6 @@ promiseCreator) {
863
869
  },
864
870
  getInitialState: function getInitialState(_, input) {
865
871
  return {
866
- canceled: false,
867
872
  status: 'active',
868
873
  data: undefined,
869
874
  input: input
@@ -898,12 +903,11 @@ function fromObservable(observableCreator) {
898
903
  id = _ref.id,
899
904
  defer = _ref.defer;
900
905
  var _event = toSCXMLEvent(event);
901
- if (state.canceled) {
906
+ if (state.status !== 'active') {
902
907
  return state;
903
908
  }
904
909
  switch (_event.name) {
905
910
  case nextEventType:
906
- state.data = event.data.data;
907
911
  // match the exact timing of events sent by machines
908
912
  // send actions are not executed immediately
909
913
  defer(function () {
@@ -915,21 +919,29 @@ function fromObservable(observableCreator) {
915
919
  origin: self
916
920
  }));
917
921
  });
918
- return state;
922
+ return _objectSpread2(_objectSpread2({}, state), {}, {
923
+ data: event.data.data
924
+ });
919
925
  case errorEventType:
920
- state.status = 'error';
921
- delete state.input;
922
- state.data = _event.data.data;
923
- return state;
926
+ return _objectSpread2(_objectSpread2({}, state), {}, {
927
+ status: 'error',
928
+ input: undefined,
929
+ data: _event.data.data,
930
+ subscription: undefined
931
+ });
924
932
  case completeEventType:
925
- state.status = 'done';
926
- delete state.input;
927
- return state;
933
+ return _objectSpread2(_objectSpread2({}, state), {}, {
934
+ status: 'done',
935
+ input: undefined,
936
+ subscription: undefined
937
+ });
928
938
  case stopSignalType:
929
- state.canceled = true;
930
- delete state.input;
931
939
  state.subscription.unsubscribe();
932
- return state;
940
+ return _objectSpread2(_objectSpread2({}, state), {}, {
941
+ status: 'canceled',
942
+ input: undefined,
943
+ subscription: undefined
944
+ });
933
945
  default:
934
946
  return state;
935
947
  }
@@ -937,7 +949,6 @@ function fromObservable(observableCreator) {
937
949
  getInitialState: function getInitialState(_, input) {
938
950
  return {
939
951
  subscription: undefined,
940
- canceled: false,
941
952
  status: 'active',
942
953
  data: undefined,
943
954
  input: input
@@ -975,12 +986,10 @@ function fromObservable(observableCreator) {
975
986
  return state.data;
976
987
  },
977
988
  getPersistedState: function getPersistedState(_ref3) {
978
- var canceled = _ref3.canceled,
979
- status = _ref3.status,
989
+ var status = _ref3.status,
980
990
  data = _ref3.data,
981
991
  input = _ref3.input;
982
992
  return {
983
- canceled: canceled,
984
993
  status: status,
985
994
  data: data,
986
995
  input: input
@@ -1015,24 +1024,30 @@ function fromEventObservable(lazyObservable) {
1015
1024
  var behavior = {
1016
1025
  transition: function transition(state, event) {
1017
1026
  var _event = toSCXMLEvent(event);
1018
- if (state.canceled) {
1027
+ if (state.status !== 'active') {
1019
1028
  return state;
1020
1029
  }
1021
1030
  switch (_event.name) {
1022
1031
  case errorEventType:
1023
- state.status = 'error';
1024
- delete state.input;
1025
- state.data = _event.data.data;
1026
- return state;
1032
+ return _objectSpread2(_objectSpread2({}, state), {}, {
1033
+ status: 'error',
1034
+ input: undefined,
1035
+ data: _event.data.data,
1036
+ subscription: undefined
1037
+ });
1027
1038
  case completeEventType:
1028
- state.status = 'done';
1029
- delete state.input;
1030
- return state;
1039
+ return _objectSpread2(_objectSpread2({}, state), {}, {
1040
+ status: 'done',
1041
+ input: undefined,
1042
+ subscription: undefined
1043
+ });
1031
1044
  case stopSignalType:
1032
- state.canceled = true;
1033
- delete state.input;
1034
1045
  state.subscription.unsubscribe();
1035
- return state;
1046
+ return _objectSpread2(_objectSpread2({}, state), {}, {
1047
+ status: 'canceled',
1048
+ input: undefined,
1049
+ subscription: undefined
1050
+ });
1036
1051
  default:
1037
1052
  return state;
1038
1053
  }
@@ -1040,7 +1055,6 @@ function fromEventObservable(lazyObservable) {
1040
1055
  getInitialState: function getInitialState() {
1041
1056
  return {
1042
1057
  subscription: undefined,
1043
- canceled: false,
1044
1058
  status: 'active',
1045
1059
  data: undefined
1046
1060
  };
@@ -1077,12 +1091,10 @@ function fromEventObservable(lazyObservable) {
1077
1091
  return undefined;
1078
1092
  },
1079
1093
  getPersistedState: function getPersistedState(_ref5) {
1080
- var canceled = _ref5.canceled,
1081
- status = _ref5.status,
1094
+ var status = _ref5.status,
1082
1095
  data = _ref5.data,
1083
1096
  input = _ref5.input;
1084
1097
  return {
1085
- canceled: canceled,
1086
1098
  status: status,
1087
1099
  data: data,
1088
1100
  input: input
@@ -1116,7 +1128,7 @@ function fromCallback(invokeCallback) {
1116
1128
  var sender = function sender(eventForParent) {
1117
1129
  var _self$_parent;
1118
1130
  if (state.canceled) {
1119
- return state;
1131
+ return;
1120
1132
  }
1121
1133
  (_self$_parent = self._parent) === null || _self$_parent === void 0 ? void 0 : _self$_parent.send(toSCXMLEvent(eventForParent, {
1122
1134
  origin: self
@@ -1231,6 +1243,12 @@ function toActorRef(actorRefLike) {
1231
1243
  return void 0;
1232
1244
  }), _objectSpread2$1), actorRefLike);
1233
1245
  }
1246
+ var emptyBehavior = fromTransition(function (_) {
1247
+ return undefined;
1248
+ }, undefined);
1249
+ function createEmptyActor() {
1250
+ return interpret(emptyBehavior);
1251
+ }
1234
1252
 
1235
1253
  function createSystem() {
1236
1254
  var sessionIdCounter = 0;
@@ -1634,6 +1652,9 @@ var Interpreter = /*#__PURE__*/function () {
1634
1652
  }, {
1635
1653
  key: "send",
1636
1654
  value: function send(event) {
1655
+ if (typeof event === 'string') {
1656
+ throw new Error("Only event objects may be sent to actors; use .send({ type: \"".concat(event, "\" }) instead"));
1657
+ }
1637
1658
  var _event = toSCXMLEvent(event);
1638
1659
  if (this.status === exports.ActorStatus.Stopped) {
1639
1660
  return;
@@ -2229,7 +2250,7 @@ function getDelayedTransitions(stateNode) {
2229
2250
  var mutateEntryExit = function mutateEntryExit(delay, i) {
2230
2251
  var delayRef = isFunction(delay) ? "".concat(stateNode.id, ":delay[").concat(i, "]") : delay;
2231
2252
  var eventType = after$1(delayRef, stateNode.id);
2232
- stateNode.entry.push(send$1({
2253
+ stateNode.entry.push(raise$1({
2233
2254
  type: eventType
2234
2255
  }, {
2235
2256
  delay: delay
@@ -4010,6 +4031,9 @@ function raise$1(eventOrExpr, options) {
4010
4031
  var delaysMap = state.machine.options.delays;
4011
4032
 
4012
4033
  // TODO: helper function for resolving Expr
4034
+ if (typeof eventOrExpr === 'string') {
4035
+ throw new Error("Only event objects may be used with raise; use raise({ type: \"".concat(eventOrExpr, "\" }) instead"));
4036
+ }
4013
4037
  var resolvedEvent = toSCXMLEvent(typeof eventOrExpr === 'function' ? eventOrExpr(args) : eventOrExpr);
4014
4038
  var resolvedDelay;
4015
4039
  if (typeof params.delay === 'string') {
@@ -4060,6 +4084,27 @@ function choose$1(guards) {
4060
4084
  });
4061
4085
  }
4062
4086
 
4087
+ function pure$1(getActions) {
4088
+ return createDynamicAction({
4089
+ type: pure,
4090
+ params: {
4091
+ get: getActions
4092
+ }
4093
+ }, function (_event, _ref) {
4094
+ var _toArray;
4095
+ var state = _ref.state;
4096
+ return [state, {
4097
+ type: pure,
4098
+ params: {
4099
+ actions: (_toArray = toArray(toActionObjects(getActions({
4100
+ context: state.context,
4101
+ event: _event.data
4102
+ })))) !== null && _toArray !== void 0 ? _toArray : []
4103
+ }
4104
+ }];
4105
+ });
4106
+ }
4107
+
4063
4108
  var initEvent = toSCXMLEvent({
4064
4109
  type: init
4065
4110
  });
@@ -4232,7 +4277,7 @@ exports.and = and;
4232
4277
  exports.assign = assign$1;
4233
4278
  exports.cancel = cancel$1;
4234
4279
  exports.choose = choose$1;
4235
- exports.createDynamicAction = createDynamicAction;
4280
+ exports.createEmptyActor = createEmptyActor;
4236
4281
  exports.createInitEvent = createInitEvent;
4237
4282
  exports.createInvokeId = createInvokeId;
4238
4283
  exports.createSpawner = createSpawner;
@@ -4276,7 +4321,7 @@ exports.microstep = microstep;
4276
4321
  exports.not = not;
4277
4322
  exports.or = or;
4278
4323
  exports.pathToStateValue = pathToStateValue;
4279
- exports.pure = pure;
4324
+ exports.pure = pure$1;
4280
4325
  exports.raise = raise$1;
4281
4326
  exports.resolveActionObject = resolveActionObject;
4282
4327
  exports.resolveActionsAndContext = resolveActionsAndContext;
@@ -566,6 +566,9 @@ function send$1(eventOrExpr, options) {
566
566
  var delaysMap = state.machine.options.delays;
567
567
 
568
568
  // TODO: helper function for resolving Expr
569
+ if (typeof eventOrExpr === 'string') {
570
+ throw new Error("Only event objects may be used with sendTo; use sendTo({ type: \"".concat(eventOrExpr, "\" }) instead"));
571
+ }
569
572
  var resolvedEvent = toSCXMLEvent(isFunction(eventOrExpr) ? eventOrExpr(args) : eventOrExpr);
570
573
  var resolvedDelay;
571
574
  if (isString(params.delay)) {
@@ -863,25 +866,28 @@ promiseCreator) {
863
866
  var behavior = {
864
867
  transition: function transition(state, event) {
865
868
  var _event = toSCXMLEvent(event);
866
- if (state.canceled) {
869
+ if (state.status !== 'active') {
867
870
  return state;
868
871
  }
869
872
  var eventObject = _event.data;
870
873
  switch (_event.name) {
871
874
  case resolveEventType:
872
- state.status = 'done';
873
- state.data = eventObject.data;
874
- delete state.input;
875
- return state;
875
+ return _objectSpread2(_objectSpread2({}, state), {}, {
876
+ status: 'done',
877
+ data: eventObject.data,
878
+ input: undefined
879
+ });
876
880
  case rejectEventType:
877
- state.status = 'error';
878
- state.data = eventObject.data;
879
- delete state.input;
880
- return state;
881
+ return _objectSpread2(_objectSpread2({}, state), {}, {
882
+ status: 'error',
883
+ data: eventObject.data,
884
+ input: undefined
885
+ });
881
886
  case stopSignalType:
882
- state.canceled = true;
883
- delete state.input;
884
- return state;
887
+ return _objectSpread2(_objectSpread2({}, state), {}, {
888
+ status: 'canceled',
889
+ input: undefined
890
+ });
885
891
  default:
886
892
  return state;
887
893
  }
@@ -910,7 +916,6 @@ promiseCreator) {
910
916
  },
911
917
  getInitialState: function getInitialState(_, input) {
912
918
  return {
913
- canceled: false,
914
919
  status: 'active',
915
920
  data: undefined,
916
921
  input: input
@@ -945,12 +950,11 @@ function fromObservable(observableCreator) {
945
950
  id = _ref.id,
946
951
  defer = _ref.defer;
947
952
  var _event = toSCXMLEvent(event);
948
- if (state.canceled) {
953
+ if (state.status !== 'active') {
949
954
  return state;
950
955
  }
951
956
  switch (_event.name) {
952
957
  case nextEventType:
953
- state.data = event.data.data;
954
958
  // match the exact timing of events sent by machines
955
959
  // send actions are not executed immediately
956
960
  defer(function () {
@@ -962,21 +966,29 @@ function fromObservable(observableCreator) {
962
966
  origin: self
963
967
  }));
964
968
  });
965
- return state;
969
+ return _objectSpread2(_objectSpread2({}, state), {}, {
970
+ data: event.data.data
971
+ });
966
972
  case errorEventType:
967
- state.status = 'error';
968
- delete state.input;
969
- state.data = _event.data.data;
970
- return state;
973
+ return _objectSpread2(_objectSpread2({}, state), {}, {
974
+ status: 'error',
975
+ input: undefined,
976
+ data: _event.data.data,
977
+ subscription: undefined
978
+ });
971
979
  case completeEventType:
972
- state.status = 'done';
973
- delete state.input;
974
- return state;
980
+ return _objectSpread2(_objectSpread2({}, state), {}, {
981
+ status: 'done',
982
+ input: undefined,
983
+ subscription: undefined
984
+ });
975
985
  case stopSignalType:
976
- state.canceled = true;
977
- delete state.input;
978
986
  state.subscription.unsubscribe();
979
- return state;
987
+ return _objectSpread2(_objectSpread2({}, state), {}, {
988
+ status: 'canceled',
989
+ input: undefined,
990
+ subscription: undefined
991
+ });
980
992
  default:
981
993
  return state;
982
994
  }
@@ -984,7 +996,6 @@ function fromObservable(observableCreator) {
984
996
  getInitialState: function getInitialState(_, input) {
985
997
  return {
986
998
  subscription: undefined,
987
- canceled: false,
988
999
  status: 'active',
989
1000
  data: undefined,
990
1001
  input: input
@@ -1022,12 +1033,10 @@ function fromObservable(observableCreator) {
1022
1033
  return state.data;
1023
1034
  },
1024
1035
  getPersistedState: function getPersistedState(_ref3) {
1025
- var canceled = _ref3.canceled,
1026
- status = _ref3.status,
1036
+ var status = _ref3.status,
1027
1037
  data = _ref3.data,
1028
1038
  input = _ref3.input;
1029
1039
  return {
1030
- canceled: canceled,
1031
1040
  status: status,
1032
1041
  data: data,
1033
1042
  input: input
@@ -1062,24 +1071,30 @@ function fromEventObservable(lazyObservable) {
1062
1071
  var behavior = {
1063
1072
  transition: function transition(state, event) {
1064
1073
  var _event = toSCXMLEvent(event);
1065
- if (state.canceled) {
1074
+ if (state.status !== 'active') {
1066
1075
  return state;
1067
1076
  }
1068
1077
  switch (_event.name) {
1069
1078
  case errorEventType:
1070
- state.status = 'error';
1071
- delete state.input;
1072
- state.data = _event.data.data;
1073
- return state;
1079
+ return _objectSpread2(_objectSpread2({}, state), {}, {
1080
+ status: 'error',
1081
+ input: undefined,
1082
+ data: _event.data.data,
1083
+ subscription: undefined
1084
+ });
1074
1085
  case completeEventType:
1075
- state.status = 'done';
1076
- delete state.input;
1077
- return state;
1086
+ return _objectSpread2(_objectSpread2({}, state), {}, {
1087
+ status: 'done',
1088
+ input: undefined,
1089
+ subscription: undefined
1090
+ });
1078
1091
  case stopSignalType:
1079
- state.canceled = true;
1080
- delete state.input;
1081
1092
  state.subscription.unsubscribe();
1082
- return state;
1093
+ return _objectSpread2(_objectSpread2({}, state), {}, {
1094
+ status: 'canceled',
1095
+ input: undefined,
1096
+ subscription: undefined
1097
+ });
1083
1098
  default:
1084
1099
  return state;
1085
1100
  }
@@ -1087,7 +1102,6 @@ function fromEventObservable(lazyObservable) {
1087
1102
  getInitialState: function getInitialState() {
1088
1103
  return {
1089
1104
  subscription: undefined,
1090
- canceled: false,
1091
1105
  status: 'active',
1092
1106
  data: undefined
1093
1107
  };
@@ -1124,12 +1138,10 @@ function fromEventObservable(lazyObservable) {
1124
1138
  return undefined;
1125
1139
  },
1126
1140
  getPersistedState: function getPersistedState(_ref5) {
1127
- var canceled = _ref5.canceled,
1128
- status = _ref5.status,
1141
+ var status = _ref5.status,
1129
1142
  data = _ref5.data,
1130
1143
  input = _ref5.input;
1131
1144
  return {
1132
- canceled: canceled,
1133
1145
  status: status,
1134
1146
  data: data,
1135
1147
  input: input
@@ -1163,7 +1175,7 @@ function fromCallback(invokeCallback) {
1163
1175
  var sender = function sender(eventForParent) {
1164
1176
  var _self$_parent;
1165
1177
  if (state.canceled) {
1166
- return state;
1178
+ return;
1167
1179
  }
1168
1180
  (_self$_parent = self._parent) === null || _self$_parent === void 0 ? void 0 : _self$_parent.send(toSCXMLEvent(eventForParent, {
1169
1181
  origin: self
@@ -1278,6 +1290,12 @@ function toActorRef(actorRefLike) {
1278
1290
  return void 0;
1279
1291
  }), _objectSpread2$1), actorRefLike);
1280
1292
  }
1293
+ var emptyBehavior = fromTransition(function (_) {
1294
+ return undefined;
1295
+ }, undefined);
1296
+ function createEmptyActor() {
1297
+ return interpret(emptyBehavior);
1298
+ }
1281
1299
 
1282
1300
  function createSystem() {
1283
1301
  var sessionIdCounter = 0;
@@ -1682,6 +1700,9 @@ var Interpreter = /*#__PURE__*/function () {
1682
1700
  }, {
1683
1701
  key: "send",
1684
1702
  value: function send(event) {
1703
+ if (typeof event === 'string') {
1704
+ throw new Error("Only event objects may be sent to actors; use .send({ type: \"".concat(event, "\" }) instead"));
1705
+ }
1685
1706
  var _event = toSCXMLEvent(event);
1686
1707
  if (this.status === ActorStatus.Stopped) {
1687
1708
  // do nothing
@@ -2288,7 +2309,7 @@ function getDelayedTransitions(stateNode) {
2288
2309
  var mutateEntryExit = function mutateEntryExit(delay, i) {
2289
2310
  var delayRef = isFunction(delay) ? "".concat(stateNode.id, ":delay[").concat(i, "]") : delay;
2290
2311
  var eventType = after$1(delayRef, stateNode.id);
2291
- stateNode.entry.push(send$1({
2312
+ stateNode.entry.push(raise$1({
2292
2313
  type: eventType
2293
2314
  }, {
2294
2315
  delay: delay
@@ -4080,6 +4101,9 @@ function raise$1(eventOrExpr, options) {
4080
4101
  var delaysMap = state.machine.options.delays;
4081
4102
 
4082
4103
  // TODO: helper function for resolving Expr
4104
+ if (typeof eventOrExpr === 'string') {
4105
+ throw new Error("Only event objects may be used with raise; use raise({ type: \"".concat(eventOrExpr, "\" }) instead"));
4106
+ }
4083
4107
  var resolvedEvent = toSCXMLEvent(typeof eventOrExpr === 'function' ? eventOrExpr(args) : eventOrExpr);
4084
4108
  var resolvedDelay;
4085
4109
  if (typeof params.delay === 'string') {
@@ -4130,6 +4154,27 @@ function choose$1(guards) {
4130
4154
  });
4131
4155
  }
4132
4156
 
4157
+ function pure$1(getActions) {
4158
+ return createDynamicAction({
4159
+ type: pure,
4160
+ params: {
4161
+ get: getActions
4162
+ }
4163
+ }, function (_event, _ref) {
4164
+ var _toArray;
4165
+ var state = _ref.state;
4166
+ return [state, {
4167
+ type: pure,
4168
+ params: {
4169
+ actions: (_toArray = toArray(toActionObjects(getActions({
4170
+ context: state.context,
4171
+ event: _event.data
4172
+ })))) !== null && _toArray !== void 0 ? _toArray : []
4173
+ }
4174
+ }];
4175
+ });
4176
+ }
4177
+
4133
4178
  var initEvent = toSCXMLEvent({
4134
4179
  type: init
4135
4180
  });
@@ -4284,4 +4329,4 @@ function createInitEvent(input) {
4284
4329
  });
4285
4330
  }
4286
4331
 
4287
- export { sendTo as $, getConfiguration as A, getStateNodes as B, resolveStateValue as C, isInFinalState as D, toSCXMLEvent as E, isSCXMLErrorEvent as F, macrostep as G, transitionNode as H, _slicedToArray as I, getInitialConfiguration as J, resolveActionsAndContext as K, microstep as L, error$1 as M, NULL_EVENT as N, isStateId as O, getStateNodeByPath as P, getPersistedState as Q, resolveReferencedActor as R, State as S, interpret as T, STATE_DELIMITER as U, initEvent as V, matchesState as W, raise$1 as X, send$1 as Y, sendParent as Z, _createClass as _, toActionObjects as a, log$1 as a0, cancel$1 as a1, stop$1 as a2, assign$1 as a3, after$1 as a4, done as a5, respond as a6, forwardTo as a7, escalate as a8, choose$1 as a9, toActionObject as aA, Interpreter as aa, ActorStatus as ab, doneInvoke as ac, pathToStateValue as ad, toObserver as ae, ActionTypes as af, SpecialTargets as ag, startSignalType as ah, stopSignalType as ai, startSignal as aj, stopSignal as ak, isSignal as al, isActorRef as am, toActorRef as an, fromTransition as ao, fromPromise as ap, fromObservable as aq, fromEventObservable as ar, fromCallback as as, stateIn as at, not as au, and as av, or as aw, toGuardDefinition as ax, actionTypes as ay, resolveActionObject as az, toTransitionConfigArray as b, createDynamicAction as c, formatTransition as d, memo as e, formatTransitions as f, _createForOfIteratorHelper as g, evaluateGuard as h, _toConsumableArray as i, flatten as j, _classCallCheck as k, _defineProperty as l, mapValues as m, createInvokeId as n, toInvokeConfig as o, pure as p, _objectSpread2 as q, invoke as r, _objectWithoutProperties as s, toArray as t, getDelayedTransitions as u, formatInitialTransition as v, getCandidates as w, isString as x, createSpawner as y, createInitEvent as z };
4332
+ export { doneInvoke as $, resolveStateValue as A, isInFinalState as B, toSCXMLEvent as C, isSCXMLErrorEvent as D, macrostep as E, transitionNode as F, _slicedToArray as G, getInitialConfiguration as H, resolveActionsAndContext as I, microstep as J, error$1 as K, isStateId as L, getStateNodeByPath as M, NULL_EVENT as N, getPersistedState as O, resolveReferencedActor as P, interpret as Q, STATE_DELIMITER as R, State as S, initEvent as T, matchesState as U, sendTo as V, sendParent as W, forwardTo as X, Interpreter as Y, ActorStatus as Z, _createClass as _, formatTransition as a, assign$1 as a0, cancel$1 as a1, choose$1 as a2, log$1 as a3, pure$1 as a4, raise$1 as a5, stop$1 as a6, pathToStateValue as a7, toObserver as a8, fromPromise as a9, escalate as aA, fromObservable as aa, fromCallback as ab, fromEventObservable as ac, fromTransition as ad, stateIn as ae, not as af, and as ag, or as ah, ActionTypes as ai, SpecialTargets as aj, startSignalType as ak, stopSignalType as al, startSignal as am, stopSignal as an, isSignal as ao, isActorRef as ap, toActorRef as aq, createEmptyActor as ar, toGuardDefinition as as, actionTypes as at, resolveActionObject as au, toActionObject as av, after$1 as aw, done as ax, send$1 as ay, respond as az, memo as b, _createForOfIteratorHelper as c, _toConsumableArray as d, evaluateGuard as e, formatTransitions as f, flatten as g, _classCallCheck as h, _defineProperty as i, toActionObjects as j, toArray as k, createInvokeId as l, mapValues as m, toInvokeConfig as n, _objectSpread2 as o, invoke as p, _objectWithoutProperties as q, getDelayedTransitions as r, formatInitialTransition as s, toTransitionConfigArray as t, getCandidates as u, isString as v, createSpawner as w, createInitEvent as x, getConfiguration as y, getStateNodes as z };