Skip to content

message、Modal和notification的静态方法可能导致layer优先级异常 #54391

@FanetheDivine

Description

@FanetheDivine

Reproduction link

Edit on CodeSandbox

Steps to reproduce

点击上方按钮的任一一个
审查元素 观察到<style data-rc-order="prepend" rc-util-key="@ant-design-icons">被插入至顶部
点击下方按钮 这个style标签的内容被替换为@layer antd的版本 并且这个layer优先级变为最低 可以观察到明显的样式问题
两次尝试需要刷新页面

What is expected?

@layer antd始终保持合适的优先级

What is actually happening?

@layer antd优先级变为最低

Environment Info
antd 5.26.1
React 18.3.1
System window11
Browser Chrome

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