Skip to content

Commit

Permalink
Merge pull request #3 from RunOnFlux/master
Browse files Browse the repository at this point in the history
up
  • Loading branch information
TheTrunk authored Aug 27, 2023
2 parents e8df5f0 + e5af36e commit 9a4161d
Show file tree
Hide file tree
Showing 12 changed files with 162 additions and 119 deletions.
2 changes: 1 addition & 1 deletion android/app/src/main/AndroidManifest.xml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE"/>

<application android:name=".MainApplication" android:label="@string/app_name" android:icon="@mipmap/ic_launcher" android:roundIcon="@mipmap/ic_launcher_round" android:allowBackup="false" android:theme="@style/AppTheme">
<activity android:name=".MainActivity" android:label="@string/app_name" android:configChanges="keyboard|keyboardHidden|orientation|screenLayout|screenSize|smallestScreenSize|uiMode" android:launchMode="singleTask" android:theme="@style/SplashTheme" android:windowSoftInputMode="adjustPan" android:exported="true">
<activity android:name=".MainActivity" android:label="@string/app_name" android:configChanges="keyboard|keyboardHidden|orientation|screenLayout|screenSize|smallestScreenSize|uiMode" android:launchMode="singleTask" android:theme="@style/SplashTheme" android:windowSoftInputMode="adjustResize" android:exported="true" android:screenOrientation="portrait">
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
Expand Down
32 changes: 16 additions & 16 deletions ios/SSPKey/Info.plist
Original file line number Diff line number Diff line change
Expand Up @@ -35,22 +35,6 @@
</dict>
</dict>
</dict>
<key>NSLocationWhenInUseUsageDescription</key>
<string></string>
<key>UILaunchStoryboardName</key>
<string>LaunchScreen</string>
<key>UIRequiredDeviceCapabilities</key>
<array>
<string>armv7</string>
</array>
<key>UISupportedInterfaceOrientations</key>
<array>
<string>UIInterfaceOrientationPortrait</string>
<string>UIInterfaceOrientationLandscapeLeft</string>
<string>UIInterfaceOrientationLandscapeRight</string>
</array>
<key>UIViewControllerBasedStatusBarAppearance</key>
<false/>
<key>NSCameraUsageDescription</key>
<string>$(PRODUCT_NAME) needs access to your Camera to scan QR codes.</string>
<key>NSFaceIDUsageDescription</key>
Expand All @@ -77,5 +61,21 @@
<string>Zocial.ttf</string>
<string>Fontisto.ttf</string>
</array>
<key>UILaunchStoryboardName</key>
<string>LaunchScreen</string>
<key>UIRequiredDeviceCapabilities</key>
<array>
<string>armv7</string>
</array>
<key>UISupportedInterfaceOrientations</key>
<array>
<string>UIInterfaceOrientationPortrait</string>
</array>
<key>UISupportedInterfaceOrientations~ipad</key>
<array>
<string>UIInterfaceOrientationPortrait</string>
</array>
<key>UIViewControllerBasedStatusBarAppearance</key>
<false/>
</dict>
</plist>
6 changes: 5 additions & 1 deletion src/components/AddressDetails/AddressDetails.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -68,10 +68,11 @@ const AddressDetails = (props: { actionStatus: (status: boolean) => void }) => {
onRequestClose={() => close()}
>
<ScrollView
style={[Layout.fill, styles.modalView]}
style={[Layout.fill, styles.modalBackdrop]}
contentContainerStyle={[
Gutters.smallBPadding,
Layout.scrollSpaceBetween,
styles.modalView,
]}
>
<Text style={[Fonts.titleSmall, Fonts.textCenter]}>
Expand Down Expand Up @@ -195,6 +196,9 @@ const styles = StyleSheet.create({
shadowOpacity: 0.25,
shadowRadius: 4,
},
modalBackdrop: {
backgroundColor: 'rgba(0,0,0,0.5)',
},
eyeIcon: {
padding: 12,
},
Expand Down
8 changes: 5 additions & 3 deletions src/components/Authentication/Authentication.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -127,7 +127,7 @@ const Authentication = (props: {
<KeyboardAwareScrollView
enableOnAndroid={true}
extraScrollHeight={20}
style={[Layout.fill]}
style={[Layout.fill, styles.modalBackdrop]}
contentContainerStyle={[
Gutters.smallBPadding,
Layout.scrollSpaceBetween,
Expand Down Expand Up @@ -246,7 +246,7 @@ export default Authentication;
const styles = StyleSheet.create({
modalView: {
backgroundColor: 'white',
marginTop: 60,
marginTop: '50%',
borderRadius: 20,
padding: 20,
marginLeft: 30,
Expand All @@ -262,9 +262,11 @@ const styles = StyleSheet.create({
shadowOpacity: 0.25,
shadowRadius: 4,
height: 480,
position: 'absolute',
bottom: 40,
},
modalBackdrop: {
backgroundColor: 'rgba(0,0,0,0.5)',
},
eyeIcon: {
padding: 12,
},
Expand Down
6 changes: 5 additions & 1 deletion src/components/HelpSection/HelpSection.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -45,10 +45,11 @@ const HelpSection = (props: { actionStatus: (status: boolean) => void }) => {
onRequestClose={() => close()}
>
<ScrollView
style={[Layout.fill, styles.modalView]}
style={[Layout.fill, styles.modalBackdrop]}
contentContainerStyle={[
Gutters.smallBPadding,
Layout.scrollSpaceBetween,
styles.modalView,
]}
>
<Text style={[Fonts.titleSmall, Fonts.textCenter]}>
Expand Down Expand Up @@ -145,6 +146,9 @@ const styles = StyleSheet.create({
shadowOpacity: 0.25,
shadowRadius: 4,
},
modalBackdrop: {
backgroundColor: 'rgba(0,0,0,0.5)',
},
poweredBy: {
marginBottom: -25,
},
Expand Down
6 changes: 5 additions & 1 deletion src/components/SSPKeyDetails/SSKeyDetails.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -70,10 +70,11 @@ const SSPKeyDetails = (props: { actionStatus: (status: boolean) => void }) => {
onRequestClose={() => close()}
>
<ScrollView
style={[Layout.fill, styles.modalView]}
style={[Layout.fill, styles.modalBackdrop]}
contentContainerStyle={[
Gutters.smallBPadding,
Layout.scrollSpaceBetween,
styles.modalView,
]}
>
<Text style={[Fonts.titleSmall, Fonts.textCenter]}>
Expand Down Expand Up @@ -209,6 +210,9 @@ const styles = StyleSheet.create({
shadowOpacity: 0.25,
shadowRadius: 4,
},
modalBackdrop: {
backgroundColor: 'rgba(0,0,0,0.5)',
},
eyeIcon: {
padding: 12,
},
Expand Down
191 changes: 100 additions & 91 deletions src/components/SettingsSection/SettingsSection.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -118,115 +118,121 @@ const SettingsSection = (props: {
<KeyboardAwareScrollView
enableOnAndroid={true}
extraScrollHeight={20}
style={[Layout.fill, styles.modalView]}
style={[Layout.fill, styles.modalBackdrop]}
contentContainerStyle={[
Gutters.smallBPadding,
Layout.scrollSpaceBetween,
]}
>
<Text style={[Fonts.titleSmall, Fonts.textCenter]}>
{t('common:settings')}
</Text>
<View
style={[
Layout.fill,
Layout.relative,
Layout.fullWidth,
Layout.alignItemsCenter,
Gutters.regularTMargin,
]}
>
<View style={[Gutters.regularTMargin, Gutters.smallBMargin]}>
<Text style={[Fonts.textBold, Fonts.textSmall, Fonts.textCenter]}>
{t('home:change_pw')}
</Text>
<View style={[Layout.fill, styles.modalView]}>
<Text style={[Fonts.titleSmall, Fonts.textCenter]}>
{t('common:settings')}
</Text>
<View
style={[
Layout.fill,
Layout.relative,
Layout.fullWidth,
Layout.alignItemsCenter,
Gutters.regularTMargin,
]}
>
<View style={[Gutters.regularTMargin, Gutters.smallBMargin]}>
<Text style={[Fonts.textBold, Fonts.textSmall, Fonts.textCenter]}>
{t('home:change_pw')}
</Text>
<TouchableOpacity
style={[
Common.button.outlineRounded,
Common.button.secondaryButton,
Gutters.smallTMargin,
]}
onPressIn={() => handleRestore()}
>
<Text
style={[
Fonts.textTiny,
Fonts.textBluePrimary,
Gutters.tinyVPadding,
]}
>
{t('home:change_pw_restore')}
</Text>
</TouchableOpacity>
</View>
<View style={[Gutters.regularTMargin, Gutters.smallBMargin]}>
<Text style={[Fonts.textBold, Fonts.textSmall, Fonts.textCenter]}>
{t('home:ssp_relay_server')}
</Text>
<View style={styles.passwordSection}>
<TextInput
style={styles.input}
autoCapitalize="none"
placeholder="relay.ssp.runonflux.io"
onChangeText={onChangeSSPrelay}
value={sspConfigRelay}
autoCorrect={false}
ref={textInputA}
onPressIn={() => textInputA.current?.focus()}
/>
<TouchableOpacity
onPressIn={resetSSPRelay}
style={styles.eyeIcon}
>
<Icon name="x" size={20} color={Colors.bluePrimary} />
</TouchableOpacity>
</View>
</View>
<View style={[Gutters.regularTMargin, Gutters.smallBMargin]}>
<Text style={[Fonts.textBold, Fonts.textSmall, Fonts.textCenter]}>
{t('home:flux_node_service')}
</Text>
<View style={styles.passwordSection}>
<TextInput
style={styles.input}
autoCapitalize="none"
placeholder="explorer.runonflux.io"
onChangeText={onChangeFluxNodeService}
value={fluxNodeConfig}
autoCorrect={false}
ref={textInputB}
onPressIn={() => textInputB.current?.focus()}
/>
<TouchableOpacity
onPressIn={resetFluxNodeService}
style={styles.eyeIcon}
>
<Icon name="x" size={20} color={Colors.bluePrimary} />
</TouchableOpacity>
</View>
</View>
</View>
<View style={[Layout.justifyContentEnd]}>
<TouchableOpacity
style={[
Common.button.outlineRounded,
Common.button.secondaryButton,
Common.button.rounded,
Common.button.bluePrimary,
Gutters.regularBMargin,
Gutters.smallTMargin,
]}
onPressIn={() => handleRestore()}
onPressIn={() => handleSave()}
>
<Text style={[Fonts.textRegular, Fonts.textWhite]}>
{t('common:save')}
</Text>
</TouchableOpacity>
<TouchableOpacity onPressIn={() => handleCancel()}>
<Text
style={[
Fonts.textTiny,
Fonts.textSmall,
Fonts.textBluePrimary,
Gutters.tinyVPadding,
Fonts.textCenter,
]}
>
{t('home:change_pw_restore')}
{t('common:cancel')}
</Text>
</TouchableOpacity>
</View>
<View style={[Gutters.regularTMargin, Gutters.smallBMargin]}>
<Text style={[Fonts.textBold, Fonts.textSmall, Fonts.textCenter]}>
{t('home:ssp_relay_server')}
</Text>
<View style={styles.passwordSection}>
<TextInput
style={styles.input}
autoCapitalize="none"
placeholder="relay.ssp.runonflux.io"
onChangeText={onChangeSSPrelay}
value={sspConfigRelay}
autoCorrect={false}
ref={textInputA}
onPressIn={() => textInputA.current?.focus()}
/>
<TouchableOpacity
onPressIn={resetSSPRelay}
style={styles.eyeIcon}
>
<Icon name="x" size={20} color={Colors.bluePrimary} />
</TouchableOpacity>
</View>
</View>
<View style={[Gutters.regularTMargin, Gutters.smallBMargin]}>
<Text style={[Fonts.textBold, Fonts.textSmall, Fonts.textCenter]}>
{t('home:flux_node_service')}
</Text>
<View style={styles.passwordSection}>
<TextInput
style={styles.input}
autoCapitalize="none"
placeholder="explorer.runonflux.io"
onChangeText={onChangeFluxNodeService}
value={fluxNodeConfig}
autoCorrect={false}
ref={textInputB}
onPressIn={() => textInputB.current?.focus()}
/>
<TouchableOpacity
onPressIn={resetFluxNodeService}
style={styles.eyeIcon}
>
<Icon name="x" size={20} color={Colors.bluePrimary} />
</TouchableOpacity>
</View>
</View>
</View>
<View style={[Layout.justifyContentEnd]}>
<TouchableOpacity
style={[
Common.button.rounded,
Common.button.bluePrimary,
Gutters.regularBMargin,
Gutters.smallTMargin,
]}
onPressIn={() => handleSave()}
>
<Text style={[Fonts.textRegular, Fonts.textWhite]}>
{t('common:save')}
</Text>
</TouchableOpacity>
<TouchableOpacity onPressIn={() => handleCancel()}>
<Text
style={[Fonts.textSmall, Fonts.textBluePrimary, Fonts.textCenter]}
>
{t('common:cancel')}
</Text>
</TouchableOpacity>
</View>
</KeyboardAwareScrollView>
</Modal>
Expand All @@ -250,6 +256,9 @@ const styles = StyleSheet.create({
shadowOpacity: 0.25,
shadowRadius: 4,
},
modalBackdrop: {
backgroundColor: 'rgba(0,0,0,0.5)',
},
input: {
flex: 1,
padding: 12,
Expand Down
6 changes: 5 additions & 1 deletion src/components/SyncSuccess/SyncSuccess.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -40,10 +40,11 @@ const SyncRequest = (props: {
onRequestClose={() => close()}
>
<ScrollView
style={[Layout.fill, styles.modalView]}
style={[Layout.fill, styles.modalBackdrop]}
contentContainerStyle={[
Gutters.smallBPadding,
Layout.scrollSpaceBetween,
styles.modalView,
]}
>
<View
Expand Down Expand Up @@ -119,4 +120,7 @@ const styles = StyleSheet.create({
shadowOpacity: 0.25,
shadowRadius: 4,
},
modalBackdrop: {
backgroundColor: 'rgba(0,0,0,0.5)',
},
});
Loading

0 comments on commit 9a4161d

Please sign in to comment.