FPSMS-frontend
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 

25 regels
556 B

  1. import { Box, Tooltip } from "@mui/material";
  2. import React from "react";
  3. const TwoLineCell: React.FC<{ children: React.ReactNode }> = ({ children }) => {
  4. return (
  5. <Tooltip title={children}>
  6. <Box
  7. sx={{
  8. whiteSpace: "normal",
  9. overflow: "hidden",
  10. textOverflow: "ellipsis",
  11. display: "-webkit-box",
  12. WebkitLineClamp: 2,
  13. WebkitBoxOrient: "vertical",
  14. lineHeight: "22px",
  15. }}
  16. >
  17. {children}
  18. </Box>
  19. </Tooltip>
  20. );
  21. };
  22. export default TwoLineCell;