Skip to content

Commit e44e273

Browse files
committed
fix: xstate deprecation warning on null events
1 parent 2470ccc commit e44e273

File tree

1 file changed

+4
-6
lines changed

1 file changed

+4
-6
lines changed

src/machines/overlay.ts

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -129,12 +129,10 @@ export const overlayMachine = Machine<
129129
},
130130
},
131131
transition: {
132-
on: {
133-
'': [
134-
{ target: 'immediately', cond: 'initiallyOpen' },
135-
{ target: 'smoothly', cond: 'initiallyClosed' },
136-
],
137-
},
132+
always: [
133+
{ target: 'immediately', cond: 'initiallyOpen' },
134+
{ target: 'smoothly', cond: 'initiallyClosed' },
135+
],
138136
},
139137
immediately: {
140138
initial: 'open',

0 commit comments

Comments
 (0)