mirror of
https://github.com/antebudimir/feishin.git
synced 2026-01-01 02:13:33 +00:00
Add actions table column
This commit is contained in:
parent
817675ee0e
commit
179129b7cb
6 changed files with 79 additions and 24 deletions
22
src/renderer/components/virtual-table/cells/actions-cell.tsx
Normal file
22
src/renderer/components/virtual-table/cells/actions-cell.tsx
Normal file
|
|
@ -0,0 +1,22 @@
|
|||
import type { ICellRendererParams } from '@ag-grid-community/core';
|
||||
import { RiMoreFill } from 'react-icons/ri';
|
||||
import { Button } from '/@/renderer/components/button';
|
||||
import { CellContainer } from '/@/renderer/components/virtual-table/cells/generic-cell';
|
||||
|
||||
export const ActionsCell = ({ context, api }: ICellRendererParams) => {
|
||||
return (
|
||||
<CellContainer position="center">
|
||||
<Button
|
||||
compact
|
||||
variant="subtle"
|
||||
onClick={(e) => {
|
||||
e.stopPropagation();
|
||||
e.preventDefault();
|
||||
context.onCellContextMenu(undefined, api, e);
|
||||
}}
|
||||
>
|
||||
<RiMoreFill />
|
||||
</Button>
|
||||
</CellContainer>
|
||||
);
|
||||
};
|
||||
Loading…
Add table
Add a link
Reference in a new issue