zy-react-library 1.0.13 → 1.0.14

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,4 +1,4 @@
1
- import type { FC, ReactNode } from "react";
1
+ import type { CSSProperties, FC, ReactNode } from "react";
2
2
 
3
3
  export interface HeaderBackProps {
4
4
  /** 标题 */
@@ -10,6 +10,8 @@ export interface HeaderBackProps {
10
10
  };
11
11
  /** 是否显示返回按钮,默认为 true */
12
12
  previous?: boolean;
13
+ /** 自定义样式 */
14
+ style?: CSSProperties;
13
15
  }
14
16
 
15
17
  /** 头部返回组件 */
@@ -6,10 +6,10 @@ import "./index.less";
6
6
  * 头部返回组件
7
7
  */
8
8
  function HeaderBack(props) {
9
- const { title, history, previous = true } = props;
9
+ const { title, history, previous = true, style = {} } = props;
10
10
 
11
11
  return (
12
- <div className="header-back">
12
+ <div className="header-back" style={style}>
13
13
  <div className="action">
14
14
  {
15
15
  previous
@@ -1,6 +1,7 @@
1
1
  .header-back {
2
2
  padding: 10px 20px;
3
3
  border-bottom: 1px solid #dcdfe6;
4
+ margin-bottom: 10px;
4
5
 
5
6
  .action {
6
7
  display: flex;
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "zy-react-library",
3
3
  "private": false,
4
- "version": "1.0.13",
4
+ "version": "1.0.14",
5
5
  "type": "module",
6
6
  "description": "",
7
7
  "author": "LiuJiaNan",