我无法将React-Joyride与ShadCN纸组件一起使用。
在打开纸牌时,教程将自动跳到下一步。 The issue is, that I cannot click outside the sheet to keep the tutorial running. When clicking outside of the sheet it just closes and the JoyRide component is unmounted.我试图将Joyride组件放置在表上方,以使其可单击,但这是不起作用的,因为Radix UI确实可以防止这种情况。
Has anyone experienced this to and was able to find a solution?
Anyway, I have a global state in my zustand for Joyride (isActive) which indicates if I'm running the tour.我正在使用此纸上的2件事。
prop模态 - 在Joyride运行时必须是错误的。
interactoutside-这可以防止单击外部时模态关闭 <Sheet open={isOpen} onOpenChange={handleOpenChange} modal={!isActive}>
<SheetContent
side="bottom"
className="h-[98vh] max-w-screen-lg 2xl:max-w-project p-0 mx-auto shadow-overlayShadow border-0 rounded-t-md"
onOpenAutoFocus={(e) => e.preventDefault()}
onInteractOutside={(e) => {
isActive && e.preventDefault();
}}
>