@tarojs/taro-rn 3.5.4-canary.0 → 3.5.5-alpha.0
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.
|
@@ -14,7 +14,6 @@ import PropTypes from 'prop-types';
|
|
|
14
14
|
import { View, Text, TouchableHighlight, StyleSheet, Platform } from 'react-native';
|
|
15
15
|
import { ViewPropTypes } from 'deprecated-react-native-prop-types';
|
|
16
16
|
import { initialWindowMetrics } from 'react-native-safe-area-context';
|
|
17
|
-
import { Mask } from '../Mask';
|
|
18
17
|
import { Popup } from '../Popup';
|
|
19
18
|
import V from '../variable';
|
|
20
19
|
const styles = StyleSheet.create({
|
|
@@ -63,7 +62,7 @@ const styles = StyleSheet.create({
|
|
|
63
62
|
marginBottom: ((18 * V.baseLineHeight) - 18) / 2
|
|
64
63
|
},
|
|
65
64
|
androidActionsheetCellText: {
|
|
66
|
-
textAlign: '
|
|
65
|
+
textAlign: 'center',
|
|
67
66
|
fontSize: 16,
|
|
68
67
|
marginTop: ((16 * 1.4) - 16) / 2,
|
|
69
68
|
marginBottom: ((16 * 1.4) - 16) / 2
|
|
@@ -119,24 +118,14 @@ const Index = ({ visible, style, maskStyle, onShow, onClose, menus = [], actions
|
|
|
119
118
|
textStyle
|
|
120
119
|
] }, label));
|
|
121
120
|
});
|
|
122
|
-
return
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
React.createElement(View, { style: { paddingBottom: Math.max((initialWindowMetrics === null || initialWindowMetrics === void 0 ? void 0 : initialWindowMetrics.insets.bottom) || 0, 16), backgroundColor: '#fff' } }))
|
|
131
|
-
: React.createElement(View, { style: styles.Modal },
|
|
132
|
-
React.createElement(Mask, { style: [styles.androidActionsheetWrapper, maskStyle], onPress: onClose },
|
|
133
|
-
React.createElement(View, { style: [styles.androidActionsheet, style] },
|
|
134
|
-
menus.length
|
|
135
|
-
? React.createElement(View, { style: [styles.actionsheetMenu] }, _renderMenuItems())
|
|
136
|
-
: false,
|
|
137
|
-
actions.length
|
|
138
|
-
? React.createElement(View, { style: [styles.actionsheetAction] }, _renderActions())
|
|
139
|
-
: false)));
|
|
121
|
+
return React.createElement(Popup, { visible: visible, style: [styles.iosActionsheet, style], maskStyle: maskStyle, onShow: onShow, onClose: onClose },
|
|
122
|
+
menus.length
|
|
123
|
+
? React.createElement(View, { style: [styles.actionsheetMenu] }, _renderMenuItems())
|
|
124
|
+
: false,
|
|
125
|
+
actions.length
|
|
126
|
+
? React.createElement(View, { style: [styles.actionsheetAction] }, _renderActions())
|
|
127
|
+
: false,
|
|
128
|
+
React.createElement(View, { style: { paddingBottom: Math.max((initialWindowMetrics === null || initialWindowMetrics === void 0 ? void 0 : initialWindowMetrics.insets.bottom) || 0, 16), backgroundColor: '#fff' } }));
|
|
140
129
|
};
|
|
141
130
|
Index.propTypes = {
|
|
142
131
|
autoDectect: PropTypes.bool,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ActionSheet.js","sourceRoot":"","sources":["../../../src/lib/showActionSheet/ActionSheet.tsx"],"names":[],"mappings":";;;;;;;;;;;AAAA,OAAO,KAAK,MAAM,OAAO,CAAA;AACzB,OAAO,SAAS,MAAM,YAAY,CAAA;AAClC,OAAO,EACL,IAAI,EACJ,IAAI,EACJ,kBAAkB,EAClB,UAAU,EACV,QAAQ,EACT,MAAM,cAAc,CAAA;AACrB,OAAO,EAAE,aAAa,EAAE,MAAM,oCAAoC,CAAA;AAClE,OAAO,EAAE,oBAAoB,EAAE,MAAM,gCAAgC,CAAC;AACtE,OAAO,EAAE,
|
|
1
|
+
{"version":3,"file":"ActionSheet.js","sourceRoot":"","sources":["../../../src/lib/showActionSheet/ActionSheet.tsx"],"names":[],"mappings":";;;;;;;;;;;AAAA,OAAO,KAAK,MAAM,OAAO,CAAA;AACzB,OAAO,SAAS,MAAM,YAAY,CAAA;AAClC,OAAO,EACL,IAA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ojs/taro-rn",
|
|
3
|
-
"version": "3.5.
|
|
3
|
+
"version": "3.5.5-alpha.0",
|
|
4
4
|
"description": "Taro RN framework",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"typings": "types/index.d.ts",
|
|
@@ -26,19 +26,19 @@
|
|
|
26
26
|
"@react-native-community/clipboard": "~1.5.1",
|
|
27
27
|
"@react-native-community/geolocation": "~2.1.0",
|
|
28
28
|
"@react-native-community/netinfo": "~9.3.0",
|
|
29
|
-
"@tarojs/runtime-rn": "3.5.
|
|
29
|
+
"@tarojs/runtime-rn": "3.5.5-alpha.0",
|
|
30
30
|
"babel-preset-expo": "~9.2.0",
|
|
31
31
|
"base64-js": "^1.3.0",
|
|
32
32
|
"deprecated-react-native-prop-types": "^2.3.0",
|
|
33
|
-
"expo-av": "~
|
|
33
|
+
"expo-av": "~12.0.3",
|
|
34
34
|
"expo-barcode-scanner": "~11.4.0",
|
|
35
35
|
"expo-brightness": "~10.3.0",
|
|
36
36
|
"expo-camera": "~12.3.0",
|
|
37
37
|
"expo-file-system": "~14.1.0",
|
|
38
|
-
"expo-image-picker": "~13.
|
|
38
|
+
"expo-image-picker": "~13.3.1",
|
|
39
39
|
"expo-keep-awake": "~10.2.0",
|
|
40
40
|
"expo-location": "~14.3.0",
|
|
41
|
-
"expo-modules-core": "~0.11.
|
|
41
|
+
"expo-modules-core": "~0.11.5",
|
|
42
42
|
"expo-sensors": "~11.4.0",
|
|
43
43
|
"nullthrows": "^1.1.1",
|
|
44
44
|
"prop-types": "^15.8.1",
|
|
@@ -53,11 +53,10 @@
|
|
|
53
53
|
},
|
|
54
54
|
"devDependencies": {
|
|
55
55
|
"@types/jest": "^27.4.1",
|
|
56
|
-
"@types/react": "^
|
|
57
|
-
"@types/react-native": "^0.67.7",
|
|
56
|
+
"@types/react-native": "^0.69.8",
|
|
58
57
|
"fbjs-scripts": "^3.0.1",
|
|
59
|
-
"metro-react-native-babel-preset": "^0.
|
|
60
|
-
"react-native": "^0.
|
|
58
|
+
"metro-react-native-babel-preset": "^0.72.1",
|
|
59
|
+
"react-native": "^0.70.0"
|
|
61
60
|
},
|
|
62
61
|
"peerDependencies": {
|
|
63
62
|
"@react-native-async-storage/async-storage": "~1.17.7",
|
|
@@ -65,15 +64,15 @@
|
|
|
65
64
|
"@react-native-community/clipboard": "~1.5.1",
|
|
66
65
|
"@react-native-community/geolocation": "~2.1.0",
|
|
67
66
|
"@react-native-community/netinfo": "~9.3.0",
|
|
68
|
-
"expo-av": "~
|
|
67
|
+
"expo-av": "~12.0.3",
|
|
69
68
|
"expo-barcode-scanner": "~11.4.0",
|
|
70
69
|
"expo-brightness": "~10.3.0",
|
|
71
70
|
"expo-camera": "~12.3.0",
|
|
72
71
|
"expo-file-system": "~14.1.0",
|
|
73
|
-
"expo-image-picker": "~13.
|
|
72
|
+
"expo-image-picker": "~13.3.1",
|
|
74
73
|
"expo-keep-awake": "~10.2.0",
|
|
75
74
|
"expo-location": "~14.3.0",
|
|
76
|
-
"expo-modules-core": "~0.11.
|
|
75
|
+
"expo-modules-core": "~0.11.5",
|
|
77
76
|
"expo-sensors": "~11.4.0",
|
|
78
77
|
"react-native-device-info": "~10.0.2",
|
|
79
78
|
"react-native-image-resizer": "~1.4.5",
|
|
@@ -9,7 +9,6 @@ import {
|
|
|
9
9
|
} from 'react-native'
|
|
10
10
|
import { ViewPropTypes } from 'deprecated-react-native-prop-types'
|
|
11
11
|
import { initialWindowMetrics } from 'react-native-safe-area-context';
|
|
12
|
-
import { Mask } from '../Mask'
|
|
13
12
|
import { Popup } from '../Popup'
|
|
14
13
|
import V from '../variable'
|
|
15
14
|
|
|
@@ -59,7 +58,7 @@ const styles = StyleSheet.create({
|
|
|
59
58
|
marginBottom: ((18 * V.baseLineHeight) - 18) / 2
|
|
60
59
|
},
|
|
61
60
|
androidActionsheetCellText: {
|
|
62
|
-
textAlign: '
|
|
61
|
+
textAlign: 'center',
|
|
63
62
|
fontSize: 16,
|
|
64
63
|
marginTop: ((16 * 1.4) - 16) / 2,
|
|
65
64
|
marginBottom: ((16 * 1.4) - 16) / 2
|
|
@@ -145,8 +144,7 @@ const Index: React.FC<any> = ({
|
|
|
145
144
|
</TouchableHighlight>
|
|
146
145
|
)
|
|
147
146
|
|
|
148
|
-
return
|
|
149
|
-
? <Popup
|
|
147
|
+
return <Popup
|
|
150
148
|
visible={visible}
|
|
151
149
|
style={[styles.iosActionsheet, style]}
|
|
152
150
|
maskStyle={maskStyle}
|
|
@@ -165,24 +163,6 @@ const Index: React.FC<any> = ({
|
|
|
165
163
|
: false}
|
|
166
164
|
<View style={{paddingBottom: Math.max(initialWindowMetrics?.insets.bottom || 0, 16), backgroundColor: '#fff'}}></View>
|
|
167
165
|
</Popup>
|
|
168
|
-
: <View
|
|
169
|
-
style={styles.Modal}
|
|
170
|
-
>
|
|
171
|
-
<Mask style={[styles.androidActionsheetWrapper, maskStyle]} onPress={onClose}>
|
|
172
|
-
<View style={[styles.androidActionsheet, style]}>
|
|
173
|
-
{menus.length
|
|
174
|
-
? <View style={[styles.actionsheetMenu]}>
|
|
175
|
-
{_renderMenuItems()}
|
|
176
|
-
</View>
|
|
177
|
-
: false}
|
|
178
|
-
{actions.length
|
|
179
|
-
? <View style={[styles.actionsheetAction]}>
|
|
180
|
-
{_renderActions()}
|
|
181
|
-
</View>
|
|
182
|
-
: false}
|
|
183
|
-
</View>
|
|
184
|
-
</Mask>
|
|
185
|
-
</View>
|
|
186
166
|
}
|
|
187
167
|
|
|
188
168
|
Index.propTypes = {
|