Rev 1216 | Rev 1478 | Ir a la última revisión | Autoría | Comparar con el anterior | Ultima modificación | Ver Log |
import React from 'react'import { Container, styled } from '@mui/material'import { Add } from '@mui/icons-material'const Header = styled(Container)(({ theme }) => ({display: 'flex',alignItems: 'center',justifyContent: { xs: 'between', md: 'center' },position: 'relative',h1: {fontSize: '2.5rem',fontWeight: 'bold'},button: {display: 'flex',alignItems: 'center',gap: '0.5rem',position: 'relative',fontWeight: '600'}}))const TitleSection = ({ onAdd, addLabel = '', title = '', ...rest }) => {return (<Header {...rest}><h1>{title}</h1>{onAdd && (<button onClick={onAdd}><Add />{addLabel}</button>)}</Header>)}export default TitleSection