Skip to content

Commit d46399f

Browse files
committed
git commit "整理文档"
1 parent 765294d commit d46399f

File tree

41 files changed

+859
-928
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

41 files changed

+859
-928
lines changed
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.

@react-native-community/datetimepicker/DateTimePickerDemo-CAPI.tsx

+65-64
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
import React from 'react';
22
///import * as React from 'react';
3-
import {View, Pressable, ScrollView, StyleSheet, Text, TextInput, Platform, Button } from 'react-native';
3+
import { View, Pressable, ScrollView, StyleSheet, Text, TextInput, Platform, Button } from 'react-native';
44
import LinearGradient from 'react-native-linear-gradient'
5-
import DateTimePicker from 'datetimepicker';
5+
import DateTimePicker from '@react-native-community/datetimepickerdatetimepicker';
66
//import {HMLog } from '../Log';
77

88

@@ -46,176 +46,177 @@ function DateTimePickerDemo() {
4646
<View>
4747
<Text style={styles.footer_left}>style修改width</Text>
4848
<TextInput
49-
style={{height: 40, borderColor: 'gray', borderWidth: 1, width: 100 }}
49+
style={{ height: 40, borderColor: 'gray', borderWidth: 1, width: 100 }}
5050
placeholderTextColor='150'
5151
onChangeText={(text) => {
5252
setWidthCs(JSON.parse(text))
5353
}}
5454
></TextInput>
5555
<Text style={styles.footer_left}>修改textColor</Text>
5656
<TextInput
57-
style={{height: 40, borderColor: 'gray', borderWidth: 1, width: 100 }}
57+
style={{ height: 40, borderColor: 'gray', borderWidth: 1, width: 100 }}
5858
onChangeText={(text) => {
5959
setTextColorCs(text)
6060
}}
6161
></TextInput>
6262
<Text style={styles.footer_left}>修改display</Text>
6363
<TextInput
64-
style={{height: 40, borderColor: 'gray', borderWidth: 1, width: 100 }}
64+
style={{ height: 40, borderColor: 'gray', borderWidth: 1, width: 100 }}
6565
placeholder='compact'
6666
onChangeText={(text) => {
6767
setCompactCs(text)
6868
}}
6969
></TextInput>
7070
</View>
7171
<Text style={styles.footer_left}>修改value</Text>
72-
<Button title='改value为2030,7,16'onPress={()=>{
73-
setValueCs(new Date(2030,7,16))
72+
<Button title='改value为2030,7,16' onPress={() => {
73+
setValueCs(new Date(2030, 7, 16))
7474
}}
7575
></Button>
7676
<TextInput value={"设置后的value: " + valueCs}></TextInput>
77-
<View style={{minHeight:65}}>
78-
<DateTimePicker
79-
mode = 'date'
80-
display = {compactCs}
81-
value = {new Date(1701658653897)}
82-
disabled = {isDisabled}
83-
style = {{width:widthCs,opacity:1,height:65,marginTop:0}}
84-
//onChange={onTimeChange}
85-
textColor={textColorCs}
86-
minimumDate={new Date(1999,0,2)}
87-
maximumDate={new Date(2023,0,25)}
88-
/>
77+
<View style={{ minHeight: 65 }}>
78+
<DateTimePicker
79+
mode='date'
80+
display={compactCs}
81+
value={new Date(1701658653897)}
82+
disabled={isDisabled}
83+
style={{ width: widthCs, opacity: 1, height: 65, marginTop: 0 }}
84+
//onChange={onTimeChange}
85+
textColor={textColorCs}
86+
minimumDate={new Date(1999, 0, 2)}
87+
maximumDate={new Date(2023, 0, 25)}
88+
/>
8989
</View>
9090

9191
<Text style={styles.footer_right}>mode="date" display="spinner"</Text>
9292
<Text style={styles.footer_left}>修改minimumDate</Text>
93-
<TextInput
94-
style={{height:40,borderColor:'gray',borderWidth:1,width:100}}
93+
<TextInput
94+
style={{ height: 40, borderColor: 'gray', borderWidth: 1, width: 100 }}
9595
placeholder='1900,1,3'
9696
onChangeText={(text) => {
9797
setMinimumDateCs(text)
9898
}}
9999
></TextInput>
100100
<Text style={styles.footer_left}>修改maximumDate</Text>
101-
<TextInput
102-
style={{height:40,borderColor:'gray',borderWidth:1,width:100}}
101+
<TextInput
102+
style={{ height: 40, borderColor: 'gray', borderWidth: 1, width: 100 }}
103103
placeholder='2023,12,3'
104-
onChangeText = {(text) => {
104+
onChangeText={(text) => {
105105
setMaximumDateCs(text)
106106
}}
107107
></TextInput>
108-
<TextInput value = {JSON.stringify(maximumDateCs)}></TextInput>
109-
<View style = {{minHeight:minHeightCs}}>
108+
<TextInput value={JSON.stringify(maximumDateCs)}></TextInput>
109+
<View style={{ minHeight: minHeightCs }}>
110110
<DateTimePicker
111-
style = {{flex:1}}
112-
value = {valueCs}
113-
mode = "date"
114-
display = "spinner"
115-
disabled = {isDisabled}
116-
textColor = {textColorCs}
111+
style={{ flex: 1 }}
112+
value={valueCs}
113+
mode="date"
114+
display="spinner"
115+
disabled={isDisabled}
116+
textColor={textColorCs}
117117
//onChange = {onTimeChange}
118-
minimumDate = {dateChange(minimumDateCs)}
119-
maximumDate = {dateChange(maximumDateCs)}
118+
minimumDate={dateChange(minimumDateCs)}
119+
maximumDate={dateChange(maximumDateCs)}
120120
/>
121121
</View>
122-
<Text style = {styles.footer_left}>验证字段:</Text>
123-
<Text style = {styles.footer_right}>mode="time"</Text>
124-
<Button title='is24Hour' onPress={()=> {
125-
is24HourCs? setIs24HourCs(false) : setIs24HourCs(true)
122+
<Text style={styles.footer_left}>验证字段:</Text>
123+
<Text style={styles.footer_right}>mode="time"</Text>
124+
<Button title='is24Hour' onPress={() => {
125+
is24HourCs ? setIs24HourCs(false) : setIs24HourCs(true)
126126
}}></Button>
127-
<DateTimePicker
128-
mode = "time"
129-
is24Hour = {is24HourCs}
130-
value = {new Date()}
131-
textColor = {textColorCs}
132-
style = {{width:140,opacity:1,height:45,marginTOP:0}}
133-
//onChange = {onTimeChange}
134-
/>
135-
</ScrollView>
136-
)}
127+
<DateTimePicker
128+
mode="time"
129+
is24Hour={is24HourCs}
130+
value={new Date()}
131+
textColor={textColorCs}
132+
style={{ width: 140, opacity: 1, height: 45, marginTOP: 0 }}
133+
//onChange = {onTimeChange}
134+
/>
135+
</ScrollView>
136+
)
137+
}
137138

138139
const styles = StyleSheet.create({
139-
gradient:{
140+
gradient: {
140141
width: 60,
141142
height: 60,
142143
padding: 10,
143144
},
144-
prop_out_text:{
145+
prop_out_text: {
145146
height: 40,
146147
textAlign: 'left',
147148
color: '#000000',
148149
},
149-
prop_input:{
150+
prop_input: {
150151
width: 120,
151152
height: 40,
152153
borderWidth: 1,
153154
color: "black",
154155
},
155-
footer_row:{
156+
footer_row: {
156157
flexDirection: "row",
157158
height: 40,
158159
padding: 0,
159160
marginTop: 10,
160161
},
161-
footer_label:{
162+
footer_label: {
162163
color: '#000',
163164
height: 30,
164165
fontSize: 20,
165166
paddingRight: 12,
166167
textAlign: 'left',
167168
},
168-
top_title_center:{
169+
top_title_center: {
169170
color: '#000',
170171
height: 40,
171172
fontSize: 25,
172173
fontWeight: '600',
173174
paddingRight: 12,
174175
textAlign: 'center',
175176
},
176-
footer_center:{
177+
footer_center: {
177178
color: '#000',
178179
fontSize: 12,
179180
width: '100%',
180181
fontWeight: '600',
181182
paddingRight: 12,
182183
textAlign: 'center',
183184
},
184-
footer_left:{
185+
footer_left: {
185186
fontSize: 12,
186-
height:40,
187+
height: 40,
187188
paddingRight: 12,
188189
marginTop: 10,
189190
textAlign: 'left',
190191
},
191-
footer_right:{
192-
height:40,
192+
footer_right: {
193+
height: 40,
193194
fontSize: 12,
194195
fontWeight: '600',
195196
paddingRight: 12,
196197
textAlign: 'right',
197198
},
198-
container:{
199+
container: {
199200
width: '100%',
200201
height: '100%',
201202
},
202-
innerText:{
203+
innerText: {
203204
width: 50,
204205
height: 50,
205206
fontWeight: 'bold',
206207
},
207-
button:{
208+
button: {
208209
borderRadius: 5,
209210
margin: 4,
210211
paddingHorizontal: 15,
211212
},
212-
buttonText:{
213+
buttonText: {
213214
color: '#ffffff',
214215
fontFamily: 'normal',
215216
fontSize: 18,
216217
margin: 10,
217218
},
218-
buttonContainer:{
219+
buttonContainer: {
219220
flexDirection: 'row',
220221
flexWrap: 'wrap',
221222
justifyContent: 'space-between',

@react-native-community/push-notification-ios/PushNotificationDemo.tsx

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
import React, { useState } from 'react';
22
import { View, Text } from 'react-native';
33
import { Button } from 'react-native';
4-
import PushNotification from '@react-native-oh-tpl/push-notification-ios';
4+
import PushNotification from '@react-native-community/push-notification-ios';
55

66
export const PushNotificationDemo = () => {
77

@react-native-community/toolbar-android/RtlDemo.tsx

-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
import React, { useState } from 'react';
22
import { StyleSheet, View, Text } from 'react-native';
3-
// import ToolbarAndroid from '@react-native-oh-tpl/toolbar-android';
43
import ToolbarAndroid from '@react-native-community/toolbar-android';
54

65
function App({ }): JSX.Element {

@react-native-community/toolbar-android/TitleAndActionDemo.tsx

-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
import React, { useState } from 'react';
22
import { StyleSheet, View, Text } from 'react-native';
3-
// import ToolbarAndroid from '@react-native-oh-tpl/toolbar-android';
43
import ToolbarAndroid from '@react-native-community/toolbar-android';
54

65
function App({ }): JSX.Element {

@react-native-community/toolbar-android/TitleAndLogoActionDemo.tsx

-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
import React, { useState } from 'react';
22
import { StyleSheet, View, Text } from 'react-native';
3-
// import ToolbarAndroid from '@react-native-oh-tpl/toolbar-android';
43
import ToolbarAndroid from '@react-native-community/toolbar-android';
54

65
function App({ }): JSX.Element {

@react-native-community/toolbar-android/TitleAndNavLogoDemo.tsx

-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
import React, { useState } from 'react';
22
import { StyleSheet, View, Text } from 'react-native';
3-
// import ToolbarAndroid from '@react-native-oh-tpl/toolbar-android';
43
import ToolbarAndroid from '@react-native-community/toolbar-android';
54

65
function App({ }): JSX.Element {

@react-native-community/toolbar-android/TitleAndNavLogoLessActionDemo.tsx

-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
import React, { useState } from 'react';
22
import { StyleSheet, View, Text } from 'react-native';
3-
// import ToolbarAndroid from '@react-native-oh-tpl/toolbar-android';
43
import ToolbarAndroid from '@react-native-community/toolbar-android';
54

65
function App({ }): JSX.Element {

@react-native-community/toolbar-android/TitleAndNavLogoMoreActionDemo.tsx

-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
import React, { useState } from 'react';
22
import { StyleSheet, View, Text } from 'react-native';
3-
// import ToolbarAndroid from '@react-native-oh-tpl/toolbar-android';
43
import ToolbarAndroid from '@react-native-community/toolbar-android';
54

65
function App({ }): JSX.Element {

@react-native-cookies/cookies/Cookies.tsx

+1-1
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
import React, { useState, useRef } from 'react';
1818
import {ScrollView, StyleSheet, Text ,View, TouchableOpacity} from 'react-native';
1919
import CookieManager from '@react-native-cookies/cookies';
20-
import { WebView } from '@react-native-oh-tpl/react-native-webview';
20+
import { WebView } from 'react-native-webview';
2121

2222
export interface Cookie {
2323
name: string;
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.

0 commit comments

Comments
 (0)