From b865569ce253e35304bde23366b2ce1cbe67e5f7 Mon Sep 17 00:00:00 2001 From: Linus Rath <139418639+rathlinus@users.noreply.github.com> Date: Wed, 28 Oct 2026 04:29:50 +0100 Subject: [PATCH] fix: skip tour steps whose target sits in a closed drawer on the phone --- components/tour/__tests__/tour.test.tsx | 5 +++++ components/tour/tour-overlay.tsx | 8 ++++++-- 2 files changed, 11 insertions(+), 2 deletions(-) diff --git a/components/tour/__tests__/tour.test.tsx b/components/tour/__tests__/tour.test.tsx index 64bd27601..6c0b1de38 100644 --- a/components/tour/__tests__/tour.test.tsx +++ b/components/tour/__tests__/tour.test.tsx @@ -64,6 +64,11 @@ describe('tour targets', () => { expect(findTourTarget('[data-tour="one"]')?.id).toBe('tabbar'); }); + it('ignores a copy in a closed drawer', () => { + anchors('
'); + expect(findTourTarget('[data-tour="one"]')).toBeNull(); + }); + it('skips a step whose target is in the page but not shown, instead of leaving the user behind the overlay', () => { anchors(''); render(