Visualizer for XState machines
#209 45cdb47
Thanks @farskid! - Embedded Mode!
The visualizer/inspector can now be used in embedded mode. In this mode, some parts of the application can be configured such as control buttons, panning, zooming, etc.
The embed preview frame lets users configure how they want the embedded visualizer to look:
#198 784ded9
Thanks @mattpocock! - Added generated OG images to visualized machine links. You can copy these links yourself to embed an up-to-date image of your visualized machine - for instance in docs. Here's where the share button is in the viz:
#246 22f1724
Thanks @Andarist! - Added a hand icon to the canvas' toolbar:
This allows you to enable the "pan mode" to drag the canvas around without holding the spacebar button down at the same time.
4a0f041
Thanks @Andarist! - Fixed an issue with right-side panels getting cut off after stretching them and shrinking back with the resize handle.fbb2f00
Thanks @mattpocock! - Added support for using setInterval, setTimeout, clearInterval and clearTimeout in the viz.#217 92a2bba
Thanks @mattpocock! - Added a button to allow users to report any issues they find, using a GitHub issue template.
e074059
Thanks @mattpocock! - When you press visualize, machines will now automatically 'fit to view'. This prevents various bugs around state machines appearing not to be visible, when they're actually just off screen.#214 b9020a6
Thanks @davidkpiano! - Multiple actors are now correctly visualized in the actors panel. This includes actors that are:
createMachine(...)
(automatically interpreted by default)invoke: { ... }
spawn(...)
#215 f030057
Thanks @mattpocock! - Added a welcome area for new users to help new folks understand what the viz can do.
#210 a8dbee6
Thanks @davidkpiano! - You can now click the Fit to view button to fit your entire diagram into view:
https://user-images.githubusercontent.com/1093738/130982742-f9523cd9-ca51-4981-ae94-68ba72971577.mp4
fd35c53
Thanks @Andarist! - Fixed an issue with action buttons for the editor being often left out of the screen after viewport resizes.a1b7379
Thanks @Andarist! - Fixed an issue with global keybindings being also triggered when providing input to input-like elements.#228 7ca7e9a
Thanks @davidkpiano! - The layout algorithm was parenting some of the edges incorrectly. This has been fixed.
fd64139
Thanks @davidkpiano! - In the visualized machine, the entire event is now clickable.77e808b
Thanks @davidkpiano! - Styles for invoked actors are now consistent with other action styles.80f6966
Thanks @Andarist! - All keyboard shortcuts and keyboard-based interactions should now only allow platform-specific meta keys to be used. That means that on Mac they work with CMD and on other platforms they work with Ctrl.87ffc50
Thanks @davidkpiano! - Sometimes, initial states will end up in an unexpected place, such as all the way to the right of the graph. This was due to the graph layout algorithm trying to prioritize all transitions to point to the right, even transitions cycling back to the initial state. Now, transitions coming from the initial state are prioritized over all others, to ensure that the initial state ends up in an expected top-left placement.1d69848
Thanks @Andarist! - Fixed an issue with inspector crashing on some inline action objects used in the config.3ed3c0d
Thanks @davidkpiano! - The graph layout algorithm (using ELK) is now more resilient to layout failures caused by some layout options (such as compaction), so heuristics have been applied that make it more resilient to potential layout failures.