Skip to content

Commit ffb3b9c

Browse files
committed
Merge branch 'development'
2 parents f82fb76 + 0156a36 commit ffb3b9c

56 files changed

Lines changed: 4017 additions & 1982 deletions

Some content is hidden

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

.github/workflows/deploy-android.yaml

Lines changed: 72 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,6 @@
11
name: "publish Android"
22

33
on:
4-
push:
5-
branches:
6-
- main
74
workflow_dispatch:
85

96
jobs:
@@ -23,10 +20,15 @@ jobs:
2320

2421
- name: Install Rust stable
2522
uses: dtolnay/rust-toolchain@stable
23+
24+
- name: Install Android targets
25+
run: rustup target add aarch64-linux-android armv7-linux-androideabi i686-linux-android x86_64-linux-android
26+
2627
- name: Install cargo tauri
2728
run: |
2829
cargo install tauri-cli --version "^2.0.0" --locked
29-
cargo tauri android init
30+
- name: Tauri Info
31+
run: cargo tauri info
3032

3133
- name: Install frontend dependencies
3234
uses: pnpm/action-setup@v4
@@ -40,12 +42,62 @@ jobs:
4042
distribution: "temurin"
4143
java-version: "17"
4244

43-
- name: Install OpenSSL (if needed)
45+
- name: Cache NDK
46+
id: cache-ndk
47+
uses: actions/cache@v4
48+
with:
49+
# Path where NDK version 29.0.13113456 is expected to be installed by setup-android
50+
path: /usr/local/lib/android/sdk/ndk/29.0.13113456
51+
key: ndk-${{ runner.os }}-29.0.13113456
52+
53+
- name: Setup Android SDK and NDK
54+
uses: android-actions/setup-android@v3
55+
with:
56+
cmdline-tools-version: 12266719 # v16
57+
58+
- name: Install NDK
59+
run: sdkmanager "ndk;29.0.13113456"
60+
- name: Install CMake
61+
run: sdkmanager "cmake;4.0.2"
62+
63+
- name: Set main environment variables
64+
run: |
65+
echo "NDK_HOME=$ANDROID_HOME/ndk/29.0.13113456" >> $GITHUB_ENV
66+
echo "ANDROID_NDK_HOME=$ANDROID_HOME/ndk/29.0.13113456" >> $GITHUB_ENV
67+
echo "ANDROID_NDK=$ANDROID_HOME/ndk/29.0.13113456" >> $GITHUB_ENV
68+
echo "CMAKE=$ANDROID_HOME/cmake/4.0.2/bin/cmake" >> $GITHUB_ENV
69+
70+
echo "TOOLCHAIN=$ANDROID_NDK_HOME/toolchains/llvm/prebuilt/linux-x86_64" >> $GITHUB_ENV
71+
echo "TARGET=aarch64-linux-android" >> $GITHUB_ENV
72+
echo "API=34" >> $GITHUB_ENV
73+
- name: Set NDK variables
4474
run: |
45-
if ! command -v openssl &> /dev/null; then
46-
sudo apt-get update
47-
sudo apt-get install -y openssl
48-
fi
75+
echo "AR=$TOOLCHAIN/bin/llvm-ar" >> $GITHUB_ENV
76+
echo "CC=$TOOLCHAIN/bin/$TARGET$API-clang" >> $GITHUB_ENV
77+
echo "AS=$CC" >> $GITHUB_ENV
78+
echo "CXX=$TOOLCHAIN/bin/$TARGET$API-clang++" >> $GITHUB_ENV
79+
echo "LD=$TOOLCHAIN/bin/ld" >> $GITHUB_ENV
80+
echo "RANLIB=$TOOLCHAIN/bin/llvm-ranlib" >> $GITHUB_ENV
81+
echo "STRIP=$TOOLCHAIN/bin/llvm-strip" >> $GITHUB_ENV
82+
83+
echo "PATH=$PATH:$ANDROID_HOME/cmdline-tools/latest/bin" >> $GITHUB_ENV
84+
echo "PATH=$PATH:$TOOLCHAIN/bin" >> $GITHUB_ENV
85+
86+
- name: Initialize Android project
87+
run: cargo tauri android init
88+
89+
- name: Copy build.gradle.kts
90+
run: |
91+
rm src-tauri/gen/android/app/build.gradle.kts
92+
yes | cp -rf scripts/android/build.gradle.kts src-tauri/gen/android/app/build.gradle.kts
93+
94+
- name: Install OpenSSL development packages
95+
run: |
96+
sudo apt-get update
97+
sudo apt-get install -y openssl libssl-dev pkg-config
98+
# Info
99+
openssl version -d
100+
echo "OPENSSL_DIR=/usr/lib/ssl" >> $GITHUB_ENV
49101
50102
- name: Decrypt Android keystore
51103
run: |
@@ -60,11 +112,20 @@ jobs:
60112
password=${{ secrets.KEYSTORE_PASSWORD }}
61113
keyAlias=upload
62114
storeFile=${{ github.workspace }}/upload-keystore.jks
63-
EOF
64-
115+
#EOF
65116
- name: Publish Android
66117
env:
67118
ANDROID_KEYSTORE_PASSWORD: ${{ secrets.KEYSTORE_PASSWORD }}
68119
ANDROID_KEY_ALIAS_PASSWORD: ${{ secrets.KEYSTORE_PASSWORD }}
69120
run: |
70121
pnpm publish-android
122+
- name: Upload Android artifact
123+
uses: actions/upload-artifact@v4
124+
with:
125+
# Name of the artifact to upload.
126+
# Optional. Default is 'artifact'
127+
name: app-bundle
128+
# A file, directory or wildcard pattern that describes what to upload
129+
# Required.
130+
#
131+
path: src-tauri/gen/android/app/build/outputs/bundle/universalRelease/app-universal-release.aab

.github/workflows/deploy-ios.yaml

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,6 @@
11
name: "publish iOS"
22

33
on:
4-
push:
5-
branches:
6-
- main
74
workflow_dispatch:
85

96
# These permissions are needed to interact with GitHub's OIDC Token endpoint

app/home/components/feed.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,8 @@ export const feed = [
22
{
33
id: 1,
44
user: {
5-
name: "Alex Morgan",
6-
avatar: "https://api.dicebear.com/7.x/identicon/svg?seed=alexmorgan",
5+
name: "Nowhere Man (demo)",
6+
avatar: "https://api.dicebear.com/7.x/identicon/svg?seed=nowhereman",
77
wallet: "7k3h...2x9v",
88
},
99
time: "2 hours ago",
@@ -16,7 +16,7 @@ export const feed = [
1616
{
1717
id: 2,
1818
user: {
19-
name: "Alex Morgan",
19+
name: "Taxman (demo)",
2020
avatar: "https://api.dicebear.com/7.x/identicon/svg?seed=alexmorgan",
2121
wallet: "7k3h...2x9v",
2222
},
@@ -27,4 +27,4 @@ export const feed = [
2727
"https://images.unsplash.com/photo-1506744038136-46273834b3fb?auto=format&fit=crop&w=480&q=80", // coffee
2828
amount: "-250 USDC",
2929
},
30-
];
30+
];

app/home/components/onboarding_card_airdrop.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ export default function OnboardingCardAirdrop({
3434
setError(null);
3535
try {
3636
const now = Date.now();
37-
const message = `I want my BACH ${now}`;
37+
const message = `I want my $BACH ${now}`;
3838
await invoke<string>("sign_message", { message });
3939
setModalOpen(false);
4040
setShowConfetti(true);
@@ -96,7 +96,7 @@ export default function OnboardingCardAirdrop({
9696
letterSpacing: 1,
9797
}}
9898
>
99-
🎉 Claim Your BACH Airdrop!
99+
🎉 Claim Your $BACH Airdrop!
100100
</Typography>
101101
{error ? (
102102
<Box sx={{ mt: 2 }}>

app/home/components/onboarding_card_username.tsx

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -95,7 +95,9 @@ export default function OnboardingCardUsername({
9595
variant="outlined"
9696
placeholder="Enter your username"
9797
value={username}
98-
onChange={(e) => setUsername(e.target.value)}
98+
onChange={(e: React.ChangeEvent<HTMLInputElement>) =>
99+
setUsername(e.target.value)
100+
}
99101
sx={{
100102
mb: 2,
101103
bgcolor: "#f3f4f6",

app/home/page.tsx

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -47,9 +47,10 @@ export default function HomeFeedPage() {
4747
alignItems: "center",
4848
}}
4949
>
50-
<Box sx={{ width: "100%", maxWidth: 480, pt: 3, pb: 2 }}>
50+
<Box sx={{ width: "100%", maxWidth: 480 }}>
5151
<Typography
52-
variant="h4"
52+
variant="h5"
53+
component="h1"
5354
fontWeight="bold"
5455
align="center"
5556
sx={{ mb: 2 }}

app/layout.tsx

Lines changed: 26 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -4,12 +4,30 @@ import { AppRouterCacheProvider } from "@mui/material-nextjs/v15-appRouter";
44
import { AppLockProvider } from "../lib/context/app-lock-context";
55
import React from "react";
66
import LayoutWithBottomBar from "./components/layout-with-bottom-bar";
7+
import {
8+
ThemeProvider,
9+
createTheme,
10+
useColorScheme,
11+
} from "@mui/material/styles";
12+
import CssBaseline from "@mui/material/CssBaseline";
713

814
export default function RootLayout({
915
children,
1016
}: {
1117
children: React.ReactNode;
1218
}) {
19+
const { mode, setMode } = useColorScheme();
20+
21+
if (!mode) {
22+
setMode("light");
23+
}
24+
25+
const darkTheme = createTheme({
26+
colorSchemes: {
27+
dark: true,
28+
},
29+
});
30+
1331
return (
1432
<html lang="en">
1533
<head>
@@ -25,11 +43,14 @@ export default function RootLayout({
2543
`}</style>
2644
</head>
2745
<body>
28-
<AppRouterCacheProvider>
29-
<AppLockProvider>
30-
<LayoutWithBottomBar>{children}</LayoutWithBottomBar>
31-
</AppLockProvider>
32-
</AppRouterCacheProvider>
46+
<ThemeProvider theme={darkTheme} defaultMode="light">
47+
<CssBaseline />
48+
<AppRouterCacheProvider>
49+
<AppLockProvider>
50+
<LayoutWithBottomBar>{children}</LayoutWithBottomBar>
51+
</AppLockProvider>
52+
</AppRouterCacheProvider>
53+
</ThemeProvider>
3354
</body>
3455
</html>
3556
);

app/onboarding/create-password/page.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -152,7 +152,7 @@ export default function CreatePasswordPage() {
152152
flexDirection: "column",
153153
alignItems: "center",
154154
justifyContent: "center",
155-
minHeight: "100vh",
155+
minHeight: "60vh",
156156
bgcolor: "#f5f6fa",
157157
}}
158158
>

app/onboarding/create-wallet-disclaimer/page.tsx

Lines changed: 35 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ import Box from "@mui/material/Box";
55
import Card from "@mui/material/Card";
66
import Typography from "@mui/material/Typography";
77
import Button from "@mui/material/Button";
8+
import ArrowBackIcon from "@mui/icons-material/ArrowBack";
89
import { useRouter } from "next/navigation";
910
import { selectionFeedback } from "@tauri-apps/plugin-haptics";
1011

@@ -14,7 +15,7 @@ export default function CreateWalletDisclaimerPage() {
1415
return (
1516
<Box
1617
sx={{
17-
minHeight: "100vh",
18+
minHeight: "60vh",
1819
bgcolor: "#f5f6fa",
1920
display: "flex",
2021
flexDirection: "column",
@@ -23,6 +24,35 @@ export default function CreateWalletDisclaimerPage() {
2324
p: 2,
2425
}}
2526
>
27+
<Box
28+
sx={{
29+
width: "100%",
30+
mb: 2,
31+
display: "flex",
32+
alignItems: "center",
33+
justifyContent: "space-between",
34+
}}
35+
>
36+
<Button
37+
startIcon={<ArrowBackIcon />}
38+
variant="text"
39+
color="primary"
40+
sx={{ mb: 0 }}
41+
onClick={async () => {
42+
await selectionFeedback();
43+
router.push("/");
44+
}}
45+
>
46+
Back
47+
</Button>
48+
<Typography
49+
variant="body1"
50+
fontWeight="bold"
51+
sx={{ ml: 2, flex: 1, textAlign: "right" }}
52+
>
53+
Create Wallet
54+
</Typography>
55+
</Box>
2656
<Card
2757
sx={{
2858
maxWidth: 420,
@@ -40,7 +70,10 @@ export default function CreateWalletDisclaimerPage() {
4070
>
4171
Important Disclaimer
4272
</Typography>
43-
<Typography sx={{ mb: 3, color: "#333", textAlign: "center" }}>
73+
<Typography
74+
variant="body1"
75+
sx={{ mb: 3, color: "#333", textAlign: "center" }}
76+
>
4477
You are about to create a self-custody wallet. <br />
4578
<br />
4679
<b>You are the only one who controls your wallet and funds.</b> <br />

app/onboarding/import-keypairs/page.tsx

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -87,7 +87,7 @@ export default function ImportKeypairsPage() {
8787
alignItems: "center",
8888
justifyContent: "center",
8989
position: "relative",
90-
height: "100vh",
90+
height: "60vh",
9191
}}
9292
>
9393
<Box
@@ -118,8 +118,7 @@ export default function ImportKeypairsPage() {
118118
Back
119119
</Button>
120120
<Typography
121-
variant="h4"
122-
component="h1"
121+
variant="body1"
123122
fontWeight="bold"
124123
sx={{ ml: 2, flex: 1, textAlign: "right" }}
125124
>

0 commit comments

Comments
 (0)