Commit 70f1fb05b7c3a6317ba4505ace2ec48a42739df3

Authored by liuhanchen
1 parent 8d602998

feat: 新增选中项插槽

Showing 1 changed file with 7 additions and 5 deletions   Show diff stats
packages/schema-page/index.vue
... ... @@ -72,11 +72,13 @@
72 72 <!-- 底部区域 -->
73 73 <div v-if="schema.selection !== false || schema.pagination !== false || $scopedSlots.footer" class="z-schema-page__footer">
74 74 <slot name="footer" v-bind="_slotScope">
75   - <div v-if="schema.selection !== false && selection.length > 0" class="selection-info">
76   - <span>已选中</span>
77   - <span class="num">{{ selection.length }}</span>
78   - <span>项</span>
79   - </div>
  75 + <slot name="selected" v-bind="_slotScope">
  76 + <div v-if="schema.selection !== false && selection.length > 0" class="selection-info">
  77 + <span>已选中</span>
  78 + <span class="num">{{ selection.length }}</span>
  79 + <span>项</span>
  80 + </div>
  81 + </slot>
80 82 <!-- 分页器 -->
81 83 <slot v-if="schema.pagination !== false" name="pagination" v-bind="_slotScope">
82 84 <el-pagination
... ...