🐛 Fix custom filterDropdown trigger sorter

close #14238
pull/14264/head
afc163 6 years ago committed by 偏右
parent 762167641c
commit a9c8874854

@ -31,7 +31,9 @@ exports[`Table.filter renders custom content correctly 1`] = `
<div
class="ant-dropdown ant-dropdown-placement-bottomRight ant-dropdown-hidden"
>
<div>
<div
class="ant-table-filter-dropdown"
>
<div
class="custom-filter-dropdown"
>

@ -50,7 +50,7 @@ class App extends React.Component {
filterDropdown: ({
setSelectedKeys, selectedKeys, confirm, clearFilters,
}) => (
<div className="custom-filter-dropdown">
<div style={{ padding: 8 }}>
<Input
ref={node => { this.searchInput = node; }}
placeholder={`Search ${dataIndex}`}
@ -129,12 +129,3 @@ class App extends React.Component {
ReactDOM.render(<App />, mountNode);
````
````css
.custom-filter-dropdown {
padding: 8px;
border-radius: 4px;
background: #fff;
box-shadow: 0 2px 8px rgba(0, 0, 0, .15);
}
````

@ -247,7 +247,9 @@ export default class FilterMenu<T> extends React.Component<FilterMenuProps<T>, F
}
const menus = filterDropdown ? (
<FilterDropdownMenuWrapper>{filterDropdown}</FilterDropdownMenuWrapper>
<FilterDropdownMenuWrapper className={`${prefixCls}-dropdown`}>
{filterDropdown}
</FilterDropdownMenuWrapper>
) : (
<FilterDropdownMenuWrapper className={`${prefixCls}-dropdown`}>
<Menu

Loading…
Cancel
Save