feat(hotkeys): Migrate hotkeys to customization service and fix issues with overrides (#4777)
This commit is contained in:
1 parent
4559d39a91
commit
3e6913b097
39 files changed
+814
-1552
No files matched your search
@@ -7,22 +7,25 @@ import './Onboarding.css';
|
||||
|
||||
import { hasTourBeenShown, markTourAsShown, defaultShowHandler, middleware } from './utilities';
|
||||
|
||||
const Onboarding = () => {
|
||||
const Shepherd = useShepherd();
|
||||
const location = useLocation();
|
||||
const tours = window.config.tours as Array<{
|
||||
const Onboarding = ({
|
||||
tours = [],
|
||||
}: {
|
||||
tours?: Array<{
|
||||
id: string;
|
||||
route: string;
|
||||
tourOptions: TourOptions;
|
||||
steps: StepOptions[];
|
||||
}>;
|
||||
}) => {
|
||||
const Shepherd = useShepherd();
|
||||
const location = useLocation();
|
||||
|
||||
/**
|
||||
* Show the tour if it hasn't been shown yet based on the current route.
|
||||
* Constructs a tour instance and adds steps to it based on the matching tour.
|
||||
*/
|
||||
useEffect(() => {
|
||||
if (!tours) {
|
||||
if (!tours.length) {
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user