Jack
4 years ago
committed by
GitHub
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with
4 additions and
4 deletions
-
components/transfer/index.tsx
-
components/transfer/list.tsx
|
|
@ -46,7 +46,7 @@ export type SelectAllLabel = |
|
|
|
| ((info: { selectedCount: number; totalCount: number }) => React.ReactNode); |
|
|
|
|
|
|
|
export interface TransferLocale { |
|
|
|
titles: string[]; |
|
|
|
titles: React.ReactNode[]; |
|
|
|
notFoundContent?: React.ReactNode; |
|
|
|
searchPlaceholder: string; |
|
|
|
itemUnit: string; |
|
|
@ -72,7 +72,7 @@ export interface TransferProps<RecordType> { |
|
|
|
style?: React.CSSProperties; |
|
|
|
listStyle: ((style: ListStyle) => React.CSSProperties) | React.CSSProperties; |
|
|
|
operationStyle?: React.CSSProperties; |
|
|
|
titles?: string[]; |
|
|
|
titles?: React.ReactNode[]; |
|
|
|
operations?: string[]; |
|
|
|
showSearch?: boolean; |
|
|
|
filterOption?: (inputValue: string, item: RecordType) => boolean; |
|
|
@ -164,7 +164,7 @@ class Transfer<RecordType extends TransferItem = TransferItem> extends React.Com |
|
|
|
} |
|
|
|
}; |
|
|
|
|
|
|
|
getTitles(transferLocale: TransferLocale): string[] { |
|
|
|
getTitles(transferLocale: TransferLocale): React.ReactNode[] { |
|
|
|
const { titles } = this.props; |
|
|
|
if (titles) { |
|
|
|
return titles; |
|
|
|
|
|
@ -42,7 +42,7 @@ type RenderListFunction<T> = (props: TransferListBodyProps<T>) => React.ReactNod |
|
|
|
|
|
|
|
export interface TransferListProps<RecordType> extends TransferLocale { |
|
|
|
prefixCls: string; |
|
|
|
titleText: string; |
|
|
|
titleText: React.ReactNode; |
|
|
|
dataSource: RecordType[]; |
|
|
|
filterOption?: (filterText: string, item: RecordType) => boolean; |
|
|
|
style?: React.CSSProperties; |
|
|
|