Skip to content

Commit

Permalink
fix(descriptions): fix span problem
Browse files Browse the repository at this point in the history
  • Loading branch information
flsion committed Oct 31, 2023
1 parent 0f3c502 commit 2054876
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 5 deletions.
7 changes: 4 additions & 3 deletions packages/web-vue/components/descriptions/__demo__/basic.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,9 +19,9 @@ Simply display multiple read-only fields in groups, which are generally used for
```vue
<template>
<a-space direction="vertical" size="large" fill>
<a-descriptions :data="data" title="User Info" layout="inline-horizontal"/>
<a-descriptions :data="data" title="User Info" :column="{xs:1, md:3, lg:4}">
<a-descriptions-item v-for="item of data" :label="item.label">
<a-descriptions :data="data" title="User Info" layout="inline-horizontal" />
<a-descriptions title="User Info" :column="{xs:1, md:3, lg:4}">
<a-descriptions-item v-for="item of data" :label="item.label" :span="item.span ?? 1">
<a-tag>{{ item.value }}</a-tag>
</a-descriptions-item>
</a-descriptions>
Expand All @@ -34,6 +34,7 @@ export default {
const data = [{
label: 'Name',
value: 'Socrates',
span: 3,
}, {
label: 'Mobile',
value: '123-1234-1234',
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -57,8 +57,8 @@ export default defineComponent({
});
const itemData = reactive({
index: computedIndex,
span,
index: computedIndex.value,
span: span.value,
});
if (instance?.uid) {
Expand Down

0 comments on commit 2054876

Please sign in to comment.