Skip to content

Commit

Permalink
feat: settings screen fresh look (#2893)
Browse files Browse the repository at this point in the history
* feat: settings screen refactor

feat: account banner on settings screen

feat: blink address

feat: account section ported

chore: stuff

feat: preferences

chore: security and privacy

feat: export tx

feat: login from banner

chore: empty right

feat: need help

fix: color profile for contact modal

feat: community

fix: tsx issue

chore: small stuff

feat: acc screen, auth email

feat: auth flow working

feat: tx limits

feat: perfected delete flow

chore: some more quirks

feat: upgrade trial acc

chore: upgrade for l1

feat: port complete

fix: check-code

fix: email issue

feat: ln addr

chore: addressing comments

feat: totp

feat: refetch totp and dont use caching

fix: check-code

fix: totp stuff

Update app/components/modal-tooltip/modal-tooltip.tsx

Co-authored-by: nicolasburtey <[email protected]>

Update app/i18n/en/index.ts

Co-authored-by: nicolasburtey <[email protected]>

Update app/i18n/en/index.ts

Co-authored-by: nicolasburtey <[email protected]>

Update app/screens/settings-screen/account/settings/phone.tsx

Co-authored-by: nicolasburtey <[email protected]>

Update app/screens/settings-screen/settings/account-ln-address.tsx

Co-authored-by: nicolasburtey <[email protected]>

fix: comments

test

test(e2e): updated settings screen (#2922)

chore: adding storybook

test

chore: addressing comments

fix: typo

fix: typo

fix: typo

test: e2e

test: e2e

test: e2e

test: e2e

test: e2e

fix: flickering issue save

test: e2e

chore: login method refresh in case

test: group suffix removed

* chore: LL utils - finding unused keys and removing Blink Address ones

* chore: comments

* chore: addressing most comments

* chore: security screen

* fix: rebased
  • Loading branch information
sandipndev authored Apr 5, 2024
1 parent 4a9b221 commit 2f3a3e4
Show file tree
Hide file tree
Showing 80 changed files with 2,599 additions and 1,455 deletions.
2 changes: 0 additions & 2 deletions .github/workflows/e2e.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@ jobs:
e2e-android:
name: Android
runs-on: self-hosted
timeout-minutes: 45

steps:
- uses: actions/checkout@v2
Expand Down Expand Up @@ -108,7 +107,6 @@ jobs:
e2e-ios:
name: iOS
runs-on: self-hosted
timeout-minutes: 45

steps:
- uses: actions/checkout@v2
Expand Down
1 change: 1 addition & 0 deletions .storybook/storybook.requires.js
Original file line number Diff line number Diff line change
Expand Up @@ -99,6 +99,7 @@ const getStories = () => {
"./app/screens/settings-screen/display-currency-screen.stories.tsx": require("../app/screens/settings-screen/display-currency-screen.stories.tsx"),
"./app/screens/settings-screen/language-screen.stories.tsx": require("../app/screens/settings-screen/language-screen.stories.tsx"),
"./app/screens/settings-screen/settings-screen.stories.tsx": require("../app/screens/settings-screen/settings-screen.stories.tsx"),
"./app/screens/settings-screen/settings.stories.tsx": require("../app/screens/settings-screen/settings.stories.tsx"),
"./app/screens/settings-screen/theme-screen.stories.tsx": require("../app/screens/settings-screen/theme-screen.stories.tsx"),
"./app/screens/transaction-detail-screen/transaction-detail-screen.stories.tsx": require("../app/screens/transaction-detail-screen/transaction-detail-screen.stories.tsx"),
}
Expand Down
2 changes: 1 addition & 1 deletion __tests__/hooks/use-show-warning-secure-account.spec.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import {
WarningSecureAccountDocument,
} from "@app/graphql/generated"
import { IsAuthedContextProvider } from "@app/graphql/is-authed-context"
import { useShowWarningSecureAccount } from "@app/screens/settings-screen/show-warning-secure-account"
import { useShowWarningSecureAccount } from "@app/screens/settings-screen/account/show-warning-secure-account-hook"
import { renderHook } from "@testing-library/react-hooks"

// FIXME: the mockPrice doesn't work as expect.
Expand Down
2 changes: 1 addition & 1 deletion android/fastlane/Fastfile
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,7 @@ platform :android do
file_path: ENV["GRADLE_APK_OUTPUT_PATH"]
)

max_retries = 3
max_retries = 10
retries = 0

begin
Expand Down
44 changes: 26 additions & 18 deletions android/fastlane/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,53 +15,53 @@ For _fastlane_ installation instructions, see [Installing _fastlane_](https://do

## Android

### android test
### android build

```sh
[bundle exec] fastlane android test
[bundle exec] fastlane android build
```

Runs all the tests
Build Releasable APK

### android build
### android play_store_upload

```sh
[bundle exec] fastlane android build
[bundle exec] fastlane android play_store_upload
```

Build a new version of the app
Deploy a new version to the Google Play

### android beta
### android huawei_store_upload

```sh
[bundle exec] fastlane android beta
[bundle exec] fastlane android huawei_store_upload
```

Deploy a new version to both Play Store and Huawei Store
Deploy the new version to Huawei App Gallery

### android play_store_release
### android promote_to_beta

```sh
[bundle exec] fastlane android play_store_release
[bundle exec] fastlane android promote_to_beta
```

Deploy a new version to the Google Play
Promote Internal Testing build to Beta

### android huawei_release
### android promote_to_public

```sh
[bundle exec] fastlane android huawei_release
[bundle exec] fastlane android promote_to_public
```

Deploy a new version to Huawei App Gallery
Promote Internal Testing build to Public

### android browserstack
### android public_phased_percent

```sh
[bundle exec] fastlane android browserstack
[bundle exec] fastlane android public_phased_percent
```

End to end testing on browserstack
Phased Public Rollout

### android build_e2e

Expand All @@ -71,6 +71,14 @@ End to end testing on browserstack

Build for end to end testing

### android browserstack

```sh
[bundle exec] fastlane android browserstack
```

End to end testing on browserstack

----

This README.md is auto-generated and will be re-generated every time [_fastlane_](https://fastlane.tools) is run.
Expand Down
1 change: 1 addition & 0 deletions app/assets/icons/refresh.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
24 changes: 14 additions & 10 deletions app/components/atomic/galoy-icon-button/galoy-icon-button.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,8 @@ export type GaloyIconButtonProps = {
size: "small" | "medium" | "large"
text?: string
iconOnly?: boolean
color?: string
backgroundColor?: string
}

const sizeMapping = {
Expand All @@ -29,6 +31,8 @@ export const GaloyIconButton = ({
text,
iconOnly,
disabled,
color,
backgroundColor,
...remainingProps
}: GaloyIconButtonProps & PressableProps) => {
const {
Expand All @@ -55,36 +59,36 @@ export const GaloyIconButton = ({
case iconOnly && disabled:
return {
opacity: 0.7,
color: colors.primary,
color: color || colors.primary,
backgroundColor: colors.transparent,
}
case iconOnly && pressed:
return {
opacity: 0.7,
color: colors.primary,
backgroundColor: colors.grey4,
color: color || colors.primary,
backgroundColor: backgroundColor || colors.grey4,
}
case iconOnly && !pressed:
return {
color: colors.primary,
color: color || colors.primary,
backgroundColor: colors.transparent,
}
case !iconOnly && disabled:
return {
opacity: 0.7,
color: colors.primary,
backgroundColor: colors.grey4,
color: color || colors.primary,
backgroundColor: backgroundColor || colors.grey4,
}
case !iconOnly && pressed:
return {
opacity: 0.7,
color: colors.primary,
backgroundColor: colors.grey4,
color: color || colors.primary,
backgroundColor: backgroundColor || colors.grey4,
}
case !iconOnly && !pressed:
return {
color: colors.primary,
backgroundColor: colors.grey4,
color: color || colors.primary,
backgroundColor: backgroundColor || colors.grey4,
}
default:
return {}
Expand Down
2 changes: 2 additions & 0 deletions app/components/atomic/galoy-icon/galoy-icon.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,7 @@ import Warning from "@app/assets/icons-redesign/warning.svg"
import Note from "@app/assets/icons/note.svg"
import People from "@app/assets/icons/people.svg"
import Rank from "@app/assets/icons/rank.svg"
import Refresh from "@app/assets/icons/refresh.svg"
import { makeStyles, useTheme } from "@rneui/themed"

export const icons = {
Expand Down Expand Up @@ -104,6 +105,7 @@ export const icons = {
"payment-pending": PaymentPending,
"payment-error": PaymentError,
"bell": Bell,
"refresh": Refresh,
} as const

export type IconNamesType = keyof typeof icons
Expand Down
6 changes: 3 additions & 3 deletions app/components/contact-modal/contact-modal.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -123,8 +123,8 @@ const ContactModal: React.FC<Props> = ({
return (
<ReactNativeModal
isVisible={isVisible}
backdropOpacity={0.3}
backdropColor={colors.grey3}
backdropOpacity={0.8}
backdropColor={colors.white}
onBackdropPress={toggleModal}
style={styles.modal}
>
Expand Down Expand Up @@ -163,7 +163,7 @@ const useStyles = makeStyles(({ colors }) => ({
marginHorizontal: 0,
},
listItemContainer: {
backgroundColor: colors.white,
backgroundColor: colors.grey5,
},
listItemTitle: {
color: colors.black,
Expand Down
7 changes: 4 additions & 3 deletions app/components/custom-modal/custom-modal.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -71,10 +71,11 @@ const CustomModal: React.FC<CustomModalProps> = ({
return (
<Modal
isVisible={isVisible}
backdropOpacity={0.7}
backdropColor={colors.grey3}
backdropOpacity={0.8}
backdropColor={colors.white}
backdropTransitionOutTiming={0}
avoidKeyboard={true}
onBackdropPress={toggleModal}
>
<View style={styles.container}>
{showCloseIconButton && (
Expand Down Expand Up @@ -135,7 +136,7 @@ type UseStylesProps = {

const useStyles = makeStyles(({ colors }, props: UseStylesProps) => ({
container: {
backgroundColor: colors.white,
backgroundColor: colors.grey5,
maxHeight: "95%",
minHeight: props.minHeight || "auto",
borderRadius: 16,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ import { StackNavigationProp } from "@react-navigation/stack"
import { makeStyles, Text, useTheme } from "@rneui/themed"

import { GaloyCurrencyBubble } from "../atomic/galoy-currency-bubble"
import { GaloyIcon } from "../atomic/galoy-icon"
import { GaloyIconButton } from "../atomic/galoy-icon-button"

gql`
query setDefaultAccountModal {
Expand Down Expand Up @@ -148,15 +148,21 @@ export const SetDefaultAccountModalUI: React.FC<SetDefaultAccountModalUIProps> =
return (
<Modal
isVisible={isVisible}
backdropOpacity={0.7}
backdropColor={colors.grey3}
backdropOpacity={0.8}
backdropColor={colors.white}
backdropTransitionOutTiming={0}
avoidKeyboard={true}
onBackdropPress={toggleModal}
onBackButtonPress={toggleModal}
>
<View style={styles.container}>
<TouchableOpacity style={styles.closeIcon} onPress={toggleModal}>
<GaloyIcon name="close" size={30} color={colors.grey0} />
</TouchableOpacity>
<GaloyIconButton
style={styles.closeIcon}
name="close"
size="medium"
color={colors.grey0}
onPress={toggleModal}
/>
<ScrollView
style={styles.modalCard}
persistentScrollbar={true}
Expand Down Expand Up @@ -226,7 +232,7 @@ const useStyles = makeStyles(({ colors }) => ({
flexDirection: "column",
},
container: {
backgroundColor: colors.white,
backgroundColor: colors.grey5,
maxHeight: "80%",
minHeight: "auto",
borderRadius: 16,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -175,11 +175,11 @@ export const SetLightningAddressModalUI = ({

return (
<CustomModal
title={LL.SetAddressModal.title({ bankName })}
minHeight={"50%"}
title={LL.SetAddressModal.setLightningAddress()}
minHeight={380}
toggleModal={toggleModal}
isVisible={isVisible}
primaryButtonTitle={LL.SetAddressModal.title({ bankName })}
primaryButtonTitle={LL.SetAddressModal.setLightningAddress()}
primaryButtonLoading={loading}
primaryButtonOnPress={setLightningAddress}
primaryButtonDisabled={!lnAddress}
Expand Down Expand Up @@ -274,7 +274,7 @@ const useStyles = makeStyles(({ colors }) => ({
paddingHorizontal: 12,
borderRadius: 8,
minHeight: 60,
backgroundColor: colors.grey5,
backgroundColor: colors.grey4,
alignItems: "center",
justifyContent: "space-between",
},
Expand Down
1 change: 0 additions & 1 deletion app/components/version/version.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@ import { testProps } from "../../utils/testProps"
const useStyles = makeStyles(({ colors }) => ({
version: {
color: colors.grey0,
fontSize: 18,
marginTop: 18,
textAlign: "center",
},
Expand Down
Loading

0 comments on commit 2f3a3e4

Please sign in to comment.