GithubHelp home page GithubHelp logo

Comments (15)

crazyair avatar crazyair commented on April 28, 2024 1

@ant-design/ant-design-collaborators 看看

from ant-design.

stackblitz avatar stackblitz commented on April 28, 2024

Fix this issue in StackBlitz Codeflow Start a new pull request in StackBlitz Codeflow.

from ant-design.

crazyair avatar crazyair commented on April 28, 2024

如果 Modal 在 Popover 上面后,点击页面空白处,是先关闭 Modal,再点击空白处,再关闭 Popover

from ant-design.

kiner-tang avatar kiner-tang commented on April 28, 2024

看起来是默认层级不太对的样子

from ant-design.

CooperHash avatar CooperHash commented on April 28, 2024

好像默认zIndex token是1000,popover在原基础上加了30,modal是1000,popover是1030
image

from ant-design.

CooperHash avatar CooperHash commented on April 28, 2024

按理解的话,modal的层级应该是最高的?

from ant-design.

CooperHash avatar CooperHash commented on April 28, 2024

按理解的话,modal的层级应该是最高的?

需要更改的话,我可以提个pr

from ant-design.

crazyair avatar crazyair commented on April 28, 2024

如果 Modal 中打开 Popover 呢?

from ant-design.

CooperHash avatar CooperHash commented on April 28, 2024

对哦,那这么看的话,应该是:不管谁打开谁,都是被打开的要在上面?
btw,点击空白区域的话(popover打开modal),感觉应该是取消一次?也就是关掉modal,popover仍然打开着,需要再点击一次popover才消失,类似esc按键的退出机制?(一次就退出一层)

from ant-design.

crazyair avatar crazyair commented on April 28, 2024

可以看看打开2个Modal,点击空白处,是关闭一个还是全部关闭

from ant-design.

CooperHash avatar CooperHash commented on April 28, 2024

modal中打开modal,点击空白,没问题,是先关闭2,再点击,才关闭1

from ant-design.

CooperHash avatar CooperHash commented on April 28, 2024
modal.mov

from ant-design.

crazyair avatar crazyair commented on April 28, 2024

同组件嵌套使用没问题,不同组件嵌套还是有问题,比如 Modal 放到 Popover 里面的话,关闭 Modal 会闪一下 Popover

https://stackblitz.com/edit/react-hmtytu-4tewqw?file=demo.tsx

iShot_2024-03-21_09.30.18.mp4

from ant-design.

CooperHash avatar CooperHash commented on April 28, 2024

确实

btw: 第一个demo例子感觉有点奇怪,第二个demo逻辑跟设想的一样正常弹出,后面弹出的覆盖前面弹出的

from ant-design.

crazyair avatar crazyair commented on April 28, 2024

确实

btw: 第一个demo例子感觉有点奇怪,第二个demo逻辑跟设想的一样正常弹出,后面弹出的覆盖前面弹出的

多 Modal,其实也不是嵌套写的,但是也没问题

from ant-design.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.