MCPcopy Create free account
hub / github.com/pgadmin-org/pgadmin4 / getEditCell

Function getEditCell

web/pgadmin/static/js/components/PgReactTableStyled.jsx:480–495  ·  view source on GitHub ↗
({isDisabled, title, onClick})

Source from the content-addressed store, hash-verified

478}
479
480export function getEditCell({isDisabled, title, onClick}) {
481 const Cell = ({ row }) => {
482 return <PgIconButton data-test="expand-row" title={title} icon={<EditRoundedIcon fontSize="small" />} className='pgrt-cell-button'
483 onClick={()=>{
484 onClick ? onClick(row) : row.toggleExpanded();
485 }} disabled={isDisabled?.(row)}
486 />;
487 };
488
489 Cell.displayName = 'EditCell';
490 Cell.propTypes = {
491 row: PropTypes.any,
492 };
493
494 return Cell;
495}
496
497export function getDeleteCell({isDisabled, title, onClick}) {
498 const Cell = ({ row }) => (

Callers 3

UsersFunction · 0.90
RolesFunction · 0.90
generateColumnsMethod · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected