|
- /*
- * @Author: 赵伟
- * @Date: 2024-04-17 15:25:04
- * @Description: 分区标题
- */
-
- import classNames from 'classnames';
- import './index.less';
-
- type SubAreaTitleProps = {
- /** 标题 */
- title: string;
- /** 图片 */
- image?: string;
- /** 自定义类名 */
- className?: string;
- /** 自定义样式 */
- style?: React.CSSProperties;
- };
-
- /**
- * 表单或者详情页的分区标题
- */
- function SubAreaTitle({ title, image, className, style }: SubAreaTitleProps) {
- return (
- <div className={classNames('kf-subarea-title', className)} style={style}>
- {image && (
- <img src={image} width={18} draggable={false} alt="" style={{ marginRight: '8px' }} />
- )}
- <span>{title}</span>
- </div>
- );
- }
-
- export default SubAreaTitle;
|