From Chase Kaiser: A New Quick Choice Feature – “InstantNavigation Mode”
“InstantNavigation Mode” is a new feature added to the Quick Choice component (now located in the new flowscreencomponentsbasepack) that, when set to true, triggers a navigateNext event when a visual card is selected. This allows for fast navigation through a flow, especially when additional processing is needed based on the selection before further inputs/screens can be rendered to the user.
Below, you can see how useful this can be in a mobile form factor, providing a push-button command console:
Why it was added
Currently, in order to achieve this effect an admin can either:
- Require the user to click Next in the footer on each screen to process the current input. This can lead to a lot of extra clicks in flows that require larger amounts of user input and broken into multiple screens for interim processing.
- Use conditional visibility to determine the next input shown to the user on the same screen, allowing more data to be entered on a single screen. This, however, requires that any processing elements (Get, Assign, Loop, etc.) required for each of the initial options must be executed before the screen is rendered so that each conditional input can be displayed should the user choose the corresponding option.
“InstantNavigation Mode” solves both of these issues by eliminating the extra clicks required when using standard flow navigation buttons and (with a subsequent decision element) ensures that only elements relevant to the user’s selection are executed, improving flow efficiency (a bonus side effect of which is reducing counts towards Salesforce’s governor limits, especially since they reset between each screen).
How It Works
A new InstantNavigation mode checkbox is now available in the property editor, as shown to the left.
Solution: Replacing Traditional Lightning Buttons To Create Navigation Menus
In addition to its use as a quick-picklist, “InstantNavigation Mode” can be used as a nice replacement for the lightning-button component since the number of “buttons” is dynamic and look much cleaner as the size of each is larger and the width is uniform rather than being determined by the length of the label. Another advantage to using Quick Choice navigation is the option to include custom images and descriptions in each menu item to further aid your users in getting where they need to go quickly.
*NOTE – The “Next or Finish” navigation control must be enabled in the screen setup options in order for the navigateNext event to fire when an option is selected. A footer is not required but will not affect the component’s ability to navigate should you wish to include one.