diff --git a/native/calendar/calendar-screen.react.js b/native/calendar/calendar-screen.react.js
--- a/native/calendar/calendar-screen.react.js
+++ b/native/calendar/calendar-screen.react.js
@@ -778,7 +778,7 @@
// but it is hidden by the keyboard since it is at the bottom
const { bottomInset, tabBarHeight } = this.props.dimensions;
const inputBarHeight = Platform.OS === 'android' ? 37.7 : 35.5;
- const keyboardHeight: number = Platform.select({
+ const keyboardHeight = Platform.select({
// Android doesn't include the bottomInset in this height measurement
android: event.endCoordinates.height,
default: Math.max(event.endCoordinates.height - bottomInset, 0),
diff --git a/native/chat/settings/thread-settings-category.react.js b/native/chat/settings/thread-settings-category.react.js
--- a/native/chat/settings/thread-settings-category.react.js
+++ b/native/chat/settings/thread-settings-category.react.js
@@ -77,7 +77,7 @@
);
}
-const paddingHeight: number = Platform.select({
+const paddingHeight = Platform.select({
android: 6.5,
default: 6,
});
diff --git a/native/chat/settings/thread-settings-color.react.js b/native/chat/settings/thread-settings-color.react.js
--- a/native/chat/settings/thread-settings-color.react.js
+++ b/native/chat/settings/thread-settings-color.react.js
@@ -17,7 +17,7 @@
const unboundStyles = {
colorLine: {
- lineHeight: (Platform.select({ android: 22, default: 25 }): number),
+ lineHeight: Platform.select({ android: 22, default: 25 }),
},
colorRow: {
backgroundColor: 'panelForeground',
diff --git a/native/components/edit-setting-button.react.js b/native/components/edit-setting-button.react.js
--- a/native/components/edit-setting-button.react.js
+++ b/native/components/edit-setting-button.react.js
@@ -44,7 +44,7 @@
const styles = StyleSheet.create({
editIcon: {
paddingLeft: 10,
- paddingTop: (Platform.select({ android: 1, default: 0 }): number),
+ paddingTop: Platform.select({ android: 1, default: 0 }),
textAlign: 'right',
},
});
diff --git a/native/components/pencil-icon.react.js b/native/components/pencil-icon.react.js
--- a/native/components/pencil-icon.react.js
+++ b/native/components/pencil-icon.react.js
@@ -15,7 +15,7 @@
editIcon: {
color: 'modalForegroundSecondaryLabel',
lineHeight: 20,
- paddingTop: (Platform.select({ android: 1, default: 0 }): number),
+ paddingTop: Platform.select({ android: 1, default: 0 }),
textAlign: 'right',
},
};
diff --git a/native/components/search.react.js b/native/components/search.react.js
--- a/native/components/search.react.js
+++ b/native/components/search.react.js
@@ -122,10 +122,10 @@
paddingRight: 7,
},
inactiveSearchText: {
- transform: (Platform.select({
+ transform: Platform.select({
ios: [{ translateY: 1 / 3 }],
default: undefined,
- }): ?$ReadOnlyArray<{ +translateY: number }>),
+ }),
},
searchText: {
color: 'listForegroundLabel',
diff --git a/native/crash.react.js b/native/crash.react.js
--- a/native/crash.react.js
+++ b/native/crash.react.js
@@ -248,20 +248,20 @@
},
errorReportIDText: {
color: 'black',
- fontFamily: (Platform.select({
+ fontFamily: Platform.select({
ios: 'Menlo',
default: 'monospace',
- }): string),
+ }),
fontSize: 12,
paddingRight: 8,
paddingTop: 3,
},
errorText: {
color: 'black',
- fontFamily: (Platform.select({
+ fontFamily: Platform.select({
ios: 'Menlo',
default: 'monospace',
- }): string),
+ }),
},
header: {
color: 'black',
diff --git a/native/keyboard/animated-keyboard.js b/native/keyboard/animated-keyboard.js
--- a/native/keyboard/animated-keyboard.js
+++ b/native/keyboard/animated-keyboard.js
@@ -40,7 +40,7 @@
) {
return;
}
- const keyboardHeight: number = Platform.select({
+ const keyboardHeight = Platform.select({
// Android doesn't include the bottomInset in this height measurement
android: event.endCoordinates.height,
default: Math.max(
diff --git a/native/keyboard/keyboard.js b/native/keyboard/keyboard.js
--- a/native/keyboard/keyboard.js
+++ b/native/keyboard/keyboard.js
@@ -19,7 +19,7 @@
const isIPhoneX =
Platform.OS === 'ios' && DeviceInfo.getConstants().isIPhoneX_deprecated;
-const defaultKeyboardHeight: number = Platform.select({
+const defaultKeyboardHeight = Platform.select({
ios: isIPhoneX ? 335 : 216,
android: 282.28,
});
diff --git a/native/markdown/rules.react.js b/native/markdown/rules.react.js
--- a/native/markdown/rules.react.js
+++ b/native/markdown/rules.react.js
@@ -247,10 +247,10 @@
) => {
const { isNestedQuote } = state;
const backgroundColor = isNestedQuote ? '#00000000' : '#00000066';
- const borderLeftColor = (Platform.select({
+ const borderLeftColor = Platform.select({
ios: '#00000066',
default: isNestedQuote ? '#00000066' : '#000000A3',
- }): string);
+ });
return (
: null;
+ const statusBar = isActive ? (
+
+ ) : (
+
+ );
const device = useCameraDevice(useFrontCamera ? 'front' : 'back');
let camera = null;
diff --git a/native/media/media-gallery-keyboard.react.js b/native/media/media-gallery-keyboard.react.js
--- a/native/media/media-gallery-keyboard.react.js
+++ b/native/media/media-gallery-keyboard.react.js
@@ -528,7 +528,7 @@
const { queuedMediaURIs } = this.state;
const queueCount = queuedMediaURIs ? queuedMediaURIs.size : 0;
- const bottomInset: number = Platform.select({
+ const bottomInset = Platform.select({
ios: -1 * this.props.dimensions.bottomInset,
default: 0,
});
diff --git a/native/media/save-media.js b/native/media/save-media.js
--- a/native/media/save-media.js
+++ b/native/media/save-media.js
@@ -89,7 +89,7 @@
void invalidTokenLogOut('save_media');
return;
} else if (result.reason === 'save_unsupported') {
- const os: string = Platform.select({
+ const os = Platform.select({
ios: 'iOS',
android: 'Android',
default: Platform.OS,
diff --git a/native/navigation/community-drawer-content.react.js b/native/navigation/community-drawer-content.react.js
--- a/native/navigation/community-drawer-content.react.js
+++ b/native/navigation/community-drawer-content.react.js
@@ -48,7 +48,7 @@
} from '../utils/drawer-utils.react.js';
const maxDepth = 2;
-const safeAreaEdges: $ReadOnlyArray = Platform.select({
+const safeAreaEdges = Platform.select({
ios: ['top'],
default: ['top', 'bottom'],
});
diff --git a/native/navigation/disconnected-bar.react.js b/native/navigation/disconnected-bar.react.js
--- a/native/navigation/disconnected-bar.react.js
+++ b/native/navigation/disconnected-bar.react.js
@@ -6,7 +6,7 @@
import { useSelector } from '../redux/redux-utils.js';
import { useStyles } from '../themes/colors.js';
-const expandedHeight: number = Platform.select({
+const expandedHeight = Platform.select({
android: 29.5,
default: 27,
});
diff --git a/native/push/in-app-notif.react.js b/native/push/in-app-notif.react.js
--- a/native/push/in-app-notif.react.js
+++ b/native/push/in-app-notif.react.js
@@ -64,7 +64,7 @@
width: '100%',
},
notificationContent: {
- ...(Platform.select({
+ ...Platform.select({
ios: {
marginTop: 16,
marginBottom: 6,
@@ -72,15 +72,11 @@
default: {
marginVertical: 16,
},
- }): {
- +marginTop?: number,
- +marginBottom?: number,
- +marginVertical?: number,
}),
marginHorizontal: 10,
},
text: {
- ...(Platform.select({
+ ...Platform.select({
ios: {
fontSize: 16,
color: 'black',
@@ -88,7 +84,7 @@
default: {
fontSize: 18,
},
- }): { +fontSize: number, +color?: string }),
+ }),
},
title: {
fontWeight: 'bold',
diff --git a/native/utils/alert-messages.js b/native/utils/alert-messages.js
--- a/native/utils/alert-messages.js
+++ b/native/utils/alert-messages.js
@@ -7,7 +7,7 @@
+message: string,
};
-const platformStore: string = Platform.select({
+const platformStore = Platform.select({
ios: 'App Store',
android: 'Play Store',
});