Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

在使用a-drawer嵌套抽屉时遇到的样式问题 #7366

Closed
1 task
MrMa98 opened this issue Feb 21, 2024 · 2 comments
Closed
1 task

在使用a-drawer嵌套抽屉时遇到的样式问题 #7366

MrMa98 opened this issue Feb 21, 2024 · 2 comments
Labels

Comments

@MrMa98
Copy link

MrMa98 commented Feb 21, 2024

  • I have searched the issues of this repository and believe that this is not a duplicate.

Version

4.1.0

Environment

"vue": "^3.4.15" Chrome 版本 121.0.6167.185(正式版本)win11

Reproduction link

https://github.com/MrMa98/antdv/blob/master/TestDemo.vue

Steps to reproduce

将两个抽屉同时打开

What is expected?

不会出现样式问题,从下边弹出右边样式不变

What is actually happening?

样式问题


@aShu-guo
Copy link
Contributor

aShu-guo commented Mar 5, 2024

可以这样使用,将第二层drawer从第一层drawer中的默认slot中拿出来

<template>
  <a-button type="primary" @click="showDrawer">Open</a-button>
  <a-drawer
      v-model:open="open"
      title="Multi-level drawer"
      width="520"
      :closable="false"
      :footer-style="{ textAlign: 'right' }"
      @close="onClose"
      :style="{ position: 'relative' }"
  >
    <a-button type="primary" @click="showChildrenDrawer">Two-level drawer</a-button>

    <template #footer>
      <a-button style="margin-right: 8px" @click="onClose">Cancel</a-button>
      <a-button type="primary" @click="onClose">Submit</a-button>
    </template>
  </a-drawer>

  <a-drawer v-model:open="childrenDrawer" title="Two-level Drawer" width="320" :closable="false"
            :style="{ position: 'absolute' }" >
    <a-button type="primary" @click="showChildrenDrawer">This is two-level drawer</a-button>
  </a-drawer>
</template>

Copy link

github-actions bot commented May 5, 2024

This issue is stale because it has been open 60 days with no activity. Remove stale label or comment or this will be closed in 7 days

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants