fix: improve sub table action button style
This commit is contained in:
parent
ba6f3f7f7d
commit
76e02f8ad9
@ -49,19 +49,19 @@ export default function Table(props: SimpleTableProps) {
|
|||||||
return (
|
return (
|
||||||
<div>
|
<div>
|
||||||
<div>
|
<div>
|
||||||
<Space style={{marginBottom: 14}}>
|
<Space style={{marginBottom: 14, position: 'absolute', right: 0, top: -31}}>
|
||||||
<Button type={'primary'} onClick={() => {
|
<Button size={'small'} type={'primary'} onClick={() => {
|
||||||
drawerRef.current.setVisible(true);
|
drawerRef.current.setVisible(true);
|
||||||
drawerRef.current.setIndex(undefined);
|
drawerRef.current.setIndex(undefined);
|
||||||
drawerRef.current.setData({});
|
drawerRef.current.setData({});
|
||||||
drawerRef.current.setTitle('创建子字段');
|
drawerRef.current.setTitle('新建子字段');
|
||||||
}}>创建</Button>
|
}}>新建</Button>
|
||||||
<Popconfirm title="确认删除吗?" onConfirm={() => {
|
<Popconfirm title="确认删除吗?" onConfirm={() => {
|
||||||
console.log({selectedRowKeys})
|
console.log({selectedRowKeys})
|
||||||
const newValues = value.filter(item => selectedRowKeys.indexOf(item.__id) === -1);
|
const newValues = value.filter(item => selectedRowKeys.indexOf(item.__id) === -1);
|
||||||
onChange(newValues);
|
onChange(newValues);
|
||||||
}}>
|
}}>
|
||||||
<Button>删除</Button>
|
<Button size={'small'} type={'ghost'} danger>删除</Button>
|
||||||
</Popconfirm>
|
</Popconfirm>
|
||||||
</Space>
|
</Space>
|
||||||
</div>
|
</div>
|
||||||
@ -77,7 +77,7 @@ export default function Table(props: SimpleTableProps) {
|
|||||||
console.log(newVaules);
|
console.log(newVaules);
|
||||||
}} ref={drawerRef}/>
|
}} ref={drawerRef}/>
|
||||||
<AntdTable
|
<AntdTable
|
||||||
size={'middle'}
|
size={'small'}
|
||||||
rowKey={rowKey}
|
rowKey={rowKey}
|
||||||
// loading={loading}
|
// loading={loading}
|
||||||
columns={fields2columns(schema.fields||[])}
|
columns={fields2columns(schema.fields||[])}
|
||||||
|
Loading…
Reference in New Issue
Block a user