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.

123456789101112131415161718192021222324252627
  1. import { Box } from '@mui/system';
  2. const TabPanel = ({ children, value, index, ...other }) => {
  3. return (
  4. <div
  5. role="tabpanel"
  6. hidden={value !== index}
  7. id={`simple-tabpanel-${index}`}
  8. aria-labelledby={`simple-tab-${index}`}
  9. {...other}
  10. style={{ height: '80%' }}
  11. >
  12. {value === index && (
  13. <Box
  14. display="flex"
  15. flexDirection="column"
  16. alignContent="space-between"
  17. sx={{ pt: 3, pl: 3, width: '100%', height: '100%' }}
  18. >
  19. {children}
  20. </Box>
  21. )}
  22. </div>
  23. );
  24. };
  25. export default TabPanel;