mirror of https://github.com/mue/mue.git
22 lines
624 B
JavaScript
22 lines
624 B
JavaScript
import { MdOutlineKeyboardArrowRight } from 'react-icons/md';
|
|
import React from 'react';
|
|
|
|
function Section({ title, subtitle, icon, onClick, children }) {
|
|
return (
|
|
<div className="moreSettings" onClick={onClick}>
|
|
<div className="left">
|
|
{icon}
|
|
<div className="content">
|
|
<span className="title">{title}</span>
|
|
<span className="subtitle">{subtitle}</span>
|
|
</div>
|
|
</div>
|
|
<div className="action">
|
|
{React.Children.count(children) === 0 ? <MdOutlineKeyboardArrowRight /> : children}
|
|
</div>
|
|
</div>
|
|
);
|
|
}
|
|
|
|
export { Section as default, Section };
|