mirror of
https://gitee.com/nocobase/nocobase.git
synced 2024-12-02 12:18:15 +08:00
refactor(client): allow fixed layout table and action link class (#3246)
This commit is contained in:
parent
d570a2c704
commit
3e99ad1483
@ -1,11 +1,14 @@
|
||||
import { observer } from '@formily/react';
|
||||
import React from 'react';
|
||||
import classnames from 'classnames';
|
||||
import Action from './Action';
|
||||
import { ComposedAction } from './types';
|
||||
|
||||
export const ActionLink: ComposedAction = observer(
|
||||
(props: any) => {
|
||||
return <Action {...props} component={props.component || 'a'} className={'nb-action-link'} />;
|
||||
return (
|
||||
<Action {...props} component={props.component || 'a'} className={classnames('nb-action-link', props.className)} />
|
||||
);
|
||||
},
|
||||
{ displayName: 'ActionLink' },
|
||||
);
|
||||
|
@ -538,6 +538,7 @@ export const Table: any = observer(
|
||||
ref={tableSizeRefCallback}
|
||||
rowKey={rowKey ?? defaultRowKey}
|
||||
dataSource={dataSource}
|
||||
tableLayout="auto"
|
||||
{...others}
|
||||
{...restProps}
|
||||
pagination={paginationProps}
|
||||
@ -547,7 +548,6 @@ export const Table: any = observer(
|
||||
}}
|
||||
onRow={onRow}
|
||||
rowClassName={(record) => (selectedRow.includes(record[rowKey]) ? highlightRow : '')}
|
||||
tableLayout={'auto'}
|
||||
scroll={scroll}
|
||||
columns={columns}
|
||||
expandable={{
|
||||
|
Loading…
Reference in New Issue
Block a user