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

n-data-table的树状表格在表头有分组的时候出现样式错误 #6609

Open
5 tasks done
jenifly opened this issue Dec 10, 2024 · 3 comments
Open
5 tasks done

Comments

@jenifly
Copy link

jenifly commented Dec 10, 2024

Describe the bug

image
具体情况如上

Steps to reproduce

1.添加n-data-table的分组表头
2.设置含有children的datalist

Link to minimal reproduction

System Info

win11
edge 131.0.2903.86,
naive-ui 2.40.0

Used Package Manager

pnpm

Validations

@jenifly jenifly added the untriaged need to sort label Dec 10, 2024
@jenifly
Copy link
Author

jenifly commented Dec 10, 2024

image

<template>
  <div>
    <n-data-table style="width: 400px" striped :single-line="false" :columns="c" :data="d"></n-data-table>
  </div>
</template>

<script setup lang="ts">
  const c: any = [
    {
      title: 'a',
      key: 'a',
    },
    {
      title: 'b',
      key: 'b',
      children: [
        { title: 'b1', key: 'b1' },
        { title: 'b2', key: 'b2' },
      ],
    },
  ]

  const d: any = [
    {
      a: 'a1',
      b1: 'b1',
      b2: 'b2',
      children: [
        {
          a: 'a2',
          b1: 'b2',
          b2: 'b2',
        },
        {
          a: 'a1',
          b1: 'b1',
          b2: 'b2',
        },
      ],
    },
  ]
</script>

@jahnli
Copy link
Collaborator

jahnli commented Dec 10, 2024

Provide a based on CodeSandbox or stackblitz `s Minimal Reproducible Example

@jahnli jahnli added waiting for response and removed untriaged need to sort labels Dec 10, 2024
@jenifly
Copy link
Author

jenifly commented Dec 13, 2024

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

No branches or pull requests

2 participants