Remove debug login page and refactor TransactionsTable to utilize new utility functions and cell renderers for improved code organization and maintainability.
This commit is contained in:
29
client/src/components/cellRenderers/JtlRenderer.js
Normal file
29
client/src/components/cellRenderers/JtlRenderer.js
Normal file
@@ -0,0 +1,29 @@
|
||||
import React from 'react';
|
||||
|
||||
const JtlRenderer = (params) => {
|
||||
const hasJTL = params.value;
|
||||
const backgroundColor = hasJTL ? '#388e3c' : '#f5f5f5';
|
||||
const border = hasJTL ? 'none' : '1px solid #ccc';
|
||||
|
||||
return (
|
||||
<div style={{ display: 'flex', justifyContent: 'center', alignItems: 'center', height: '100%' }}>
|
||||
<div style={{
|
||||
width: '12px',
|
||||
height: '12px',
|
||||
borderRadius: '50%',
|
||||
backgroundColor: backgroundColor,
|
||||
border: border,
|
||||
display: 'flex',
|
||||
alignItems: 'center',
|
||||
justifyContent: 'center',
|
||||
fontSize: '8px',
|
||||
color: 'white',
|
||||
fontWeight: 'bold'
|
||||
}}>
|
||||
{hasJTL && '✓'}
|
||||
</div>
|
||||
</div>
|
||||
);
|
||||
};
|
||||
|
||||
export default JtlRenderer;
|
||||
Reference in New Issue
Block a user