Commit 8879ae8d773e8dc4c252c4234eefeab9bc135a30
1 parent
f2b8bb43
fix(page-wrapper): fix `class` not working
Showing
2 changed files
with
4 additions
and
2 deletions
CHANGELOG.zh_CN.md
@@ -8,6 +8,7 @@ | @@ -8,6 +8,7 @@ | ||
8 | - **ApiTreeSelect** 修复未能正确监听`params`变化的问题 | 8 | - **ApiTreeSelect** 修复未能正确监听`params`变化的问题 |
9 | - **ImgRotateDragVerify** 修复组件`resume`方法无法调用的问题 | 9 | - **ImgRotateDragVerify** 修复组件`resume`方法无法调用的问题 |
10 | - **TableAction** 修复 stopButtonPropagation 属性某些情况下不起作用的问题 | 10 | - **TableAction** 修复 stopButtonPropagation 属性某些情况下不起作用的问题 |
11 | +- **PageWrapper** 修复`class`属性无效的问题 | ||
11 | - **BasicTable** | 12 | - **BasicTable** |
12 | - 修复可编辑单元格不支持`ellipsis`配置的问题 | 13 | - 修复可编辑单元格不支持`ellipsis`配置的问题 |
13 | - 修复全屏模式下看不到子组件弹出层(popconfirm 以及 select、treeSelect 等编辑组件)的问题 | 14 | - 修复全屏模式下看不到子组件弹出层(popconfirm 以及 select、treeSelect 等编辑组件)的问题 |
src/components/Page/src/PageWrapper.vue
@@ -3,7 +3,7 @@ | @@ -3,7 +3,7 @@ | ||
3 | <PageHeader | 3 | <PageHeader |
4 | :ghost="ghost" | 4 | :ghost="ghost" |
5 | :title="title" | 5 | :title="title" |
6 | - v-bind="$attrs" | 6 | + v-bind="omit($attrs, 'class')" |
7 | ref="headerRef" | 7 | ref="headerRef" |
8 | v-if="content || $slots.headerContent || title || getHeaderSlots.length" | 8 | v-if="content || $slots.headerContent || title || getHeaderSlots.length" |
9 | > | 9 | > |
@@ -61,7 +61,7 @@ | @@ -61,7 +61,7 @@ | ||
61 | contentClass: propTypes.string, | 61 | contentClass: propTypes.string, |
62 | fixedHeight: propTypes.bool, | 62 | fixedHeight: propTypes.bool, |
63 | }, | 63 | }, |
64 | - setup(props, { slots }) { | 64 | + setup(props, { slots, attrs }) { |
65 | const wrapperRef = ref(null); | 65 | const wrapperRef = ref(null); |
66 | const headerRef = ref(null); | 66 | const headerRef = ref(null); |
67 | const contentRef = ref(null); | 67 | const contentRef = ref(null); |
@@ -86,6 +86,7 @@ | @@ -86,6 +86,7 @@ | ||
86 | { | 86 | { |
87 | [`${prefixCls}--dense`]: props.dense, | 87 | [`${prefixCls}--dense`]: props.dense, |
88 | }, | 88 | }, |
89 | + attrs.class ?? {}, | ||
89 | ]; | 90 | ]; |
90 | }); | 91 | }); |
91 | 92 |