File tree 1 file changed +7
-1
lines changed
1 file changed +7
-1
lines changed Original file line number Diff line number Diff line change @@ -6,6 +6,7 @@ import { getSlot } from '../_util/props-util';
6
6
export default defineComponent ( {
7
7
name : 'ABreadcrumbSeparator' ,
8
8
__ANT_BREADCRUMB_SEPARATOR : true ,
9
+ inheritAttrs : false ,
9
10
props : {
10
11
prefixCls : PropTypes . string ,
11
12
} ,
@@ -16,10 +17,15 @@ export default defineComponent({
16
17
} ,
17
18
render ( ) {
18
19
const { prefixCls : customizePrefixCls } = this ;
20
+ const { separator, class : className , ...restAttrs } = this . $attrs ;
19
21
const getPrefixCls = this . configProvider . getPrefixCls ;
20
22
const prefixCls = getPrefixCls ( 'breadcrumb' , customizePrefixCls ) ;
21
23
22
24
const children = getSlot ( this ) ;
23
- return < span class = { `${ prefixCls } -separator` } > { children || '/' } </ span > ;
25
+ return (
26
+ < span class = { [ `${ prefixCls } -separator` , className ] } { ...restAttrs } >
27
+ { children . length > 0 ? children : '/' }
28
+ </ span >
29
+ ) ;
24
30
} ,
25
31
} ) ;
You can’t perform that action at this time.
0 commit comments