xstate 5.7.0 → 5.7.1

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.
@@ -52,12 +52,12 @@ interface MachineSnapshotBase<TContext extends MachineContext, TEvent extends Ev
52
52
  * Whether the current state value is a subset of the given partial state value.
53
53
  * @param partialStateValue
54
54
  */
55
- matches: (this: MachineSnapshot<TContext, TEvent, TChildren, TStateValue, TTag, TOutput>, partialStateValue: ToTestStateValue<TStateValue>) => boolean;
55
+ matches: (partialStateValue: ToTestStateValue<TStateValue>) => boolean;
56
56
  /**
57
57
  * Whether the current state nodes has a state node with the specified `tag`.
58
58
  * @param tag
59
59
  */
60
- hasTag: (this: MachineSnapshot<TContext, TEvent, TChildren, TStateValue, TTag, TOutput>, tag: TTag) => boolean;
60
+ hasTag: (tag: TTag) => boolean;
61
61
  /**
62
62
  * Determines whether sending the `event` will cause a non-forbidden transition
63
63
  * to be selected, even if the transitions have no actions nor
@@ -66,9 +66,9 @@ interface MachineSnapshotBase<TContext extends MachineContext, TEvent extends Ev
66
66
  * @param event The event to test
67
67
  * @returns Whether the event will cause a transition
68
68
  */
69
- can: (this: MachineSnapshot<TContext, TEvent, TChildren, TStateValue, TTag, TOutput>, event: TEvent) => boolean;
70
- getMeta: (this: MachineSnapshot<TContext, TEvent, TChildren, TStateValue, TTag, TOutput>) => Record<string, any>;
71
- toJSON: (this: MachineSnapshot<TContext, TEvent, TChildren, TStateValue, TTag, TOutput>) => unknown;
69
+ can: (event: TEvent) => boolean;
70
+ getMeta: () => Record<string, any>;
71
+ toJSON: () => unknown;
72
72
  }
73
73
  interface ActiveMachineSnapshot<TContext extends MachineContext, TEvent extends EventObject, TChildren extends Record<string, AnyActorRef | undefined>, TStateValue extends StateValue, TTag extends string, TOutput> extends MachineSnapshotBase<TContext, TEvent, TChildren, TStateValue, TTag, TOutput> {
74
74
  status: 'active';