Skip to content

Commit

Permalink
refactor(Form): 表单去除多余的空元素
Browse files Browse the repository at this point in the history
  • Loading branch information
D-xuanmo committed Jul 12, 2023
1 parent 174b8e7 commit e5cf00e
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion packages/dl-common/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@xuanmo/dl-common",
"version": "0.0.2-beta.14",
"version": "0.0.2-beta.15",
"author": {
"name": "xuanmo",
"email": "me@xuanmo.xin"
Expand Down
8 changes: 4 additions & 4 deletions packages/dl-common/src/form/render.vue
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
<template>
<div :class="wrapperClassName">
<div v-for="item in data" :key="item.id" :class="itemClassName">
<template v-if="item.layout.parent === 'root'">
<template v-for="item in data">
<div v-if="item.layout.parent === 'root'" :key="item.id" :class="itemClassName">
<d-form-item v-if="item.dataKey" :model="item" />
<component :is="item.component" v-else :model="item" />
</template>
</div>
</div>
</template>
</div>
</template>

Expand Down

0 comments on commit e5cf00e

Please sign in to comment.