tour: open settings when triggered from startup

Since we moved the first tour step to a possibly hidden place, we need
to make sure it is showing before starting the tour.

Fixes: https://github.com/pybricks/support/issues/823
This commit is contained in:
David Lechner
2022-12-05 13:17:37 -06:00
committed by David Lechner
parent f5fbea905f
commit 27b2c42023
2 changed files with 6 additions and 0 deletions
+5
View File
@@ -4,6 +4,11 @@
## [Unreleased]
### Fixed
- Fixed first tour item not shown if settings is not open ([support#823]).
[support#823]: https://github.com/pybricks/support/issues/823
## [2.0.0-beta.12] - 2022-12-02
### Added
+1
View File
@@ -241,6 +241,7 @@ const Tour: React.VoidFunctionComponent = () => {
// automatically show the tour on the first run only
useEffectOnce(() => {
if (showOnStartup) {
setSelectedActivity(Activity.Settings);
dispatch(tourStart());
setShowOnStartup(false);
}