Rev 3460 | Rev 3481 | Ir a la última revisión | Autoría | Comparar con el anterior | Ultima modificación | Ver Log |
import React from 'react';
import { Typography, Button, Box } from '@mui/material';
import { Add } from '@mui/icons-material';
export function PageHeader({ title, onAdd, labelAdd }) {
return (
<Box sx={{ display: 'flex', justifyContent: 'space-between', alignItems: 'center' }}>
<Typography variant='h1'>{title}</Typography>
{onAdd && (
<Button variant='contained' startIcon={<Add />} onClick={onAdd}>
{labelAdd}
</Button>
)}
</Box>
);
}