Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
这个 PR 做了什么?
修复 Tour 组件在页面滚动或窗口大小变化后,遮罩高亮区域和目标 Popover 仍停留在旧坐标的问题。
Tour 的遮罩使用固定定位,Popover 通过目标元素矩形计算绝对位置;此前两者只在挂载或打开时测量一次。现在仅在组件可见期间监听捕获阶段的
scroll和resize,并在隐藏或卸载时移除监听,保持现有 API 不变。这个 PR 是什么类型?
这个 PR 涉及以下平台:
相关 Issue:
Fixes #2933
自测说明:
pnpm exec vitest run --config vite.config.ts src/packages/__VUE/tour/__tests__/tour.spec.tsx src/packages/__VUE/popover/__tests__/popover.spec.tsx:14/14 passed(重复运行两次)pnpm exec eslint src:通过pnpm exec vue-tsc --noEmit -p tsconfig.json:通过pnpm build:通过pnpm build:taro:通过(未修改 Taro 源文件)git diff --check:通过全量 Vitest 为 492/495 通过;剩余 3 个是未修改
calendarcard测试的日期敏感既有失败。