sag_components 2.0.0-beta142 → 2.0.0-beta143
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.esm.js +36 -0
- package/dist/index.esm.js.map +1 -1
- package/dist/index.js +36 -0
- package/dist/index.js.map +1 -1
- package/dist/types/components/Table/TableBody.d.ts +5 -1
- package/dist/types/components/Table/TableBody.styles.d.ts +2 -0
- package/dist/types/components/Table/data.d.ts +3 -16
- package/package.json +1 -1
package/dist/index.esm.js
CHANGED
|
@@ -38307,6 +38307,21 @@ const DisabledTrashIconWrapper = styled.div`
|
|
|
38307
38307
|
color: #d9d9d9;
|
|
38308
38308
|
}
|
|
38309
38309
|
`;
|
|
38310
|
+
const StatusCell = styled.div`
|
|
38311
|
+
font-size: 12px;
|
|
38312
|
+
font-weight: 500;
|
|
38313
|
+
display: flex;
|
|
38314
|
+
align-items: center;
|
|
38315
|
+
gap: 6px;
|
|
38316
|
+
color: ${props => props.color || "#000"};
|
|
38317
|
+
`;
|
|
38318
|
+
const StatusCellCircle = styled.div`
|
|
38319
|
+
width: 8px;
|
|
38320
|
+
height: 8px;
|
|
38321
|
+
border-radius: 50%;
|
|
38322
|
+
border: 1px solid white;
|
|
38323
|
+
background-color: ${props => props.backgroundColor};
|
|
38324
|
+
`;
|
|
38310
38325
|
|
|
38311
38326
|
// CommentModal.styles.js
|
|
38312
38327
|
const ModalOverlay$1 = styled.div`
|
|
@@ -38680,6 +38695,19 @@ const TableBody = ({
|
|
|
38680
38695
|
resetFocus = false,
|
|
38681
38696
|
onFocusChange,
|
|
38682
38697
|
indexToShimmer = 0,
|
|
38698
|
+
statuses = [{
|
|
38699
|
+
status: 'Pending',
|
|
38700
|
+
palette: ['#F5C9A7', '#8B4513']
|
|
38701
|
+
}, {
|
|
38702
|
+
status: 'Received',
|
|
38703
|
+
palette: ['#B9D5D5', '#2F4F4F']
|
|
38704
|
+
}, {
|
|
38705
|
+
status: 'Approved',
|
|
38706
|
+
palette: ['#BEDDC3', '#2D5016']
|
|
38707
|
+
}, {
|
|
38708
|
+
status: 'Cancelled',
|
|
38709
|
+
palette: ['#EBA6AF', '#8B1538']
|
|
38710
|
+
}],
|
|
38683
38711
|
onCommentSave = () => {},
|
|
38684
38712
|
ref = null
|
|
38685
38713
|
}) => {
|
|
@@ -38865,6 +38893,14 @@ const TableBody = ({
|
|
|
38865
38893
|
}), /*#__PURE__*/React$1.createElement("span", null, "All Sent"));
|
|
38866
38894
|
}
|
|
38867
38895
|
return value;
|
|
38896
|
+
case 'status':
|
|
38897
|
+
const statusObj = statuses.find(status => status.status === value) || {};
|
|
38898
|
+
const [palette0, palette1] = statusObj.palette;
|
|
38899
|
+
return /*#__PURE__*/React$1.createElement(StatusCell, {
|
|
38900
|
+
color: palette1
|
|
38901
|
+
}, /*#__PURE__*/React$1.createElement(StatusCellCircle, {
|
|
38902
|
+
backgroundColor: palette0
|
|
38903
|
+
}), /*#__PURE__*/React$1.createElement("span", null, value));
|
|
38868
38904
|
case 'comments':
|
|
38869
38905
|
const commentText = value || '';
|
|
38870
38906
|
const hasComments = commentText.trim().length > 0;
|