Skip to content

Commit 2a014dd

Browse files
committed
docs:优化文档,优化ImageHeader组件
1 parent 60abae2 commit 2a014dd

File tree

7 files changed

+8
-11
lines changed

7 files changed

+8
-11
lines changed

example/examples/src/App.tsx

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -37,11 +37,9 @@ const App = () => {
3737
<Stack.Screen
3838
key={index}
3939
{...props}
40-
// name="Home"
41-
// options={{
42-
// header: () => null
43-
// }}
44-
// component={Home}
40+
options={{
41+
header: props.name === 'ImageHeader' ? () => null : props.header,
42+
}}
4543
/>
4644
);
4745
})}

example/examples/src/routes/ImageHeader/index.tsx

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,6 @@ export default class ImageHeaderView extends React.Component<ImageHeaderProps> {
1414
headerLeftColor="#FFF"
1515
headerLeft="返回"
1616
headerRight={<Icon name="delete" size={20} color={'##FFF'} />}
17-
statusBarColor="blue"
1817
statusBarStyle="dark-content">
1918
<Flex justify="center" style={{backgroundColor: 'white', height: 100, marginHorizontal: 20}}>
2019
<Text>111</Text>

packages/core/src/DatePicker/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ export default Demo
4141

4242
| 参数 | 说明 | 类型 | 默认值 |
4343
|------|------|-----|------|
44-
| displayType | 选择器显示类型。view表示在页面显示;modal表示在弹窗中显示;默认为modal | `view | modal` | view |
44+
| displayType | 选择器显示类型。view表示在页面显示;modal表示在弹窗中显示;默认为modal | `view modal` | view |
4545
| onChange | 修改事件 | `(value?: ItemValue[]) => void` | - |
4646
| title | 选中当前项的下标 | number | - |
4747
| visible | 是否弹窗显示 | boolean | false |

packages/core/src/ImageHeader/index.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,7 @@ const ImageHeader: FC<ImageHeaderProps> = (props) => {
7171

7272
return (
7373
<>
74-
<StatusBar barStyle={statusBarStyle} />
74+
<StatusBar barStyle={statusBarStyle} backgroundColor={headerBackgroundColor} />
7575
<ImageBackground source={headerBackgroundImg} style={{ width: '100%', height: headerHeight }}>
7676
<Flex
7777
style={{

packages/core/src/Input/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -144,7 +144,7 @@ export default Demo
144144
| `clearText` | 如果为 true,每次开始输入的时候都会清除文本框的内容。 | boolean | - |
145145
| `error` | 显示错误 | boolean | - |
146146
| `renderError` | 自定义错误提示 | React.ReactNode | - |
147-
| `border` | 边框 | `'bottom'|'top'|'left'|'right'|null|'always'` | - |
147+
| `border` | 边框 | `'bottom''top''left''right'null'always'` | - |
148148
| `borderColor` | 边框颜色 | string | - |
149149
| `clear` | 是否显示清除按钮 | boolean | - |
150150
| `clearStyle` | 清除按钮样式 | StyleProp<`TextStyle`> | - |

packages/core/src/Picker/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,7 @@ export default Demo
9696
| data | 选择项列表 | `CascadePickerItemProps[]` | `Array<CascadePickerItemProps[]>` | [] |
9797
| cols | 展示几列 | `number` | 1 |
9898
| value | 当前值 | `ItemValue[]` | [] |
99-
| displayType | 选择器显示类型。view表示在页面显示;modal表示在弹窗中显示;默认为modal | `view | modal` | view |
99+
| displayType | 选择器显示类型。view表示在页面显示;modal表示在弹窗中显示;默认为modal | `view modal` | view |
100100
| onChange | 修改事件 | `(value?: ItemValue[]) => void` | - |
101101
| title | 选中当前项的下标 | number | - |
102102
| visible | 是否弹窗显示 | boolean | false |

packages/core/src/SearchBar/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -190,7 +190,7 @@ export default Demo
190190
|------|------|-----|------|
191191
| onChangeText | 搜索框文字变化 | (value: string) => void | - |
192192
| options | 数据化配置选项内容,相比 jsx 定义会获得更好的渲染性能 | Array<`OptionsStateProps`> | - |
193-
| onChange | 事件变化回调 | string | (value: string) => void |
193+
| onChange | 事件变化回调 | (value: string) => void | - |
194194
| onFocus | 获得焦点时回调 null = 永不显示 | (e: any) => void | - |
195195
| labelInValue | 是否把每个选项的 label 包装到 value 中,会把 Select 的 value 类型从 string 变为 { key: string, label: ReactNode } 的格式 | Boolean | - |
196196
| disabled | 是否禁用 | Boolean | - |

0 commit comments

Comments
 (0)