Skip to content

Drawer 设置 mask false,在 Drawer 内打开 Modal,打开的 Drawer 位置会因为滚动消失而闪动 #49462

Open
react-component/drawer
#472

Description

@crazyair

Reproduction link

https://stackblitz.com/edit/react-etuypq?file=demo.tsx

Steps to reproduce

  1. 点击 Open Drawer
  2. 点击 Open Modal

What is expected?

Drawer 不闪动

What is actually happening?

Drawer 位置变了

Environment Info
antd 5.18.2
React latest
System mac
Browser chrome

这个看要不要内置优化掉?

Activity

  1. andybuibui commented on Jun 19, 2024

    @andybuibui

    参考:#38506 特意设定的
    你可以监听open 控制document.body.style来添加或者移除样式

  2. crazyair commented on Jun 19, 2024

    @crazyair
    MemberAuthor

    参考:#38506 特意设定的 你可以监听open 控制document.body.style来添加或者移除样式

    这个没问题,我是觉得 Drawer 可以优化,动态改 right 值

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions