Skip to content

Commit b959b01

Browse files
authored
Merge pull request #1198 from peanutprotocol/chore/sync-hotfixes
chore: sync hot-fixes from prod to staging
2 parents 012a6a8 + ac05315 commit b959b01

7 files changed

Lines changed: 34 additions & 15 deletions

File tree

src/app/(mobile-ui)/add-money/crypto/direct/page.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -92,7 +92,7 @@ export default function AddMoneyCryptoDirectPage() {
9292
icon="plus"
9393
iconSize={16}
9494
minAmount={0.1}
95-
maxAmount={4000}
95+
maxAmount={30_000}
9696
onValidationError={setError}
9797
disabled={inputTokenAmount === '0.00'}
9898
>

src/app/(mobile-ui)/layout.tsx

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,8 @@ import { useEffect, useMemo, useState } from 'react'
2121
import { twMerge } from 'tailwind-merge'
2222
import '../../styles/globals.css'
2323

24-
const publicPathRegex = /^\/(request\/pay|claim|pay\/.+$)/
24+
// Allow access to some public paths without authentication
25+
const publicPathRegex = /^\/(request\/pay|claim|pay\/.+$|support)/
2526

2627
const Layout = ({ children }: { children: React.ReactNode }) => {
2728
const pathName = usePathname()
@@ -80,7 +81,10 @@ const Layout = ({ children }: { children: React.ReactNode }) => {
8081
}
8182
}, [])
8283

83-
if (!isReady || (isFetchingUser && !user && !hasToken)) {
84+
// Allow access to public paths without authentication
85+
const isPublicPath = publicPathRegex.test(pathName)
86+
87+
if (!isReady || (isFetchingUser && !user && !hasToken && !isPublicPath)) {
8488
return (
8589
<div className="flex h-[100dvh] w-full flex-col items-center justify-center">
8690
<PeanutLoading />

src/app/[...recipient]/error.tsx

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,11 @@
22

33
import { Button, Card } from '@/components/0_Bruddle'
44
import { useEffect } from 'react'
5+
import { useRouter } from 'next/navigation'
56

67
export default function PaymentError({ error, reset }: { error: Error & { digest?: string }; reset: () => void }) {
8+
const router = useRouter()
9+
710
useEffect(() => {
811
console.error(error)
912
}, [error])
@@ -16,10 +19,13 @@ export default function PaymentError({ error, reset }: { error: Error & { digest
1619
{error.message || 'An error occurred while loading the payment page.'}
1720
</Card.Description>
1821
</Card.Header>
19-
<Card.Content>
22+
<Card.Content className="flex flex-col gap-3">
2023
<Button onClick={reset} variant="purple">
2124
Try again
2225
</Button>
26+
<Button onClick={() => router.push('/support')} variant="transparent" className="text-sm underline">
27+
Contact Support
28+
</Button>
2329
</Card.Content>
2430
</Card>
2531
)

src/components/Common/ActionListDaimoPayButton.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -135,7 +135,7 @@ const ActionListDaimoPayButton = () => {
135135
onBeforeShow={handleInitiateDaimoPayment}
136136
disabled={!usdAmount}
137137
minAmount={0.1}
138-
maxAmount={4000}
138+
maxAmount={30_000}
139139
loading={isProcessing}
140140
onValidationError={(error) => {
141141
dispatch(paymentActions.setDaimoError(error))

src/components/LandingPage/Footer.tsx

Lines changed: 3 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -57,6 +57,9 @@ const Footer = () => {
5757
</div>
5858

5959
<div className="flex gap-2">
60+
<a className="text-xl font-bold text-white" href="/support">
61+
Support
62+
</a>
6063
<a
6164
className="text-xl font-bold text-white"
6265
href="https://docs.peanut.me/"
@@ -65,14 +68,6 @@ const Footer = () => {
6568
>
6669
Docs
6770
</a>
68-
<a
69-
className="text-xl font-bold text-white"
70-
href="https://peanutprotocol.notion.site/Privacy-Policy-37debda366c941f2bbb8db8c113d8c8b"
71-
rel="noopener noreferrer"
72-
target="_blank"
73-
>
74-
Privacy
75-
</a>
7671
<a
7772
className="text-xl font-bold text-white"
7873
href="https://peanutprotocol.notion.site/Terms-of-Service-Privacy-Policy-1f245331837f4b7e860261be8374cc3a"

src/components/LandingPage/securityBuiltIn.tsx

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
import Image from 'next/image'
2+
import { Button } from '@/components/0_Bruddle'
23
import handThumbsUp from '@/assets/illustrations/hand-thumbs-up.svg'
34
import handWaving from '@/assets/illustrations/hand-waving.svg'
45
import handPeace from '@/assets/illustrations/hand-peace.svg'
@@ -81,6 +82,18 @@ export function SecurityBuiltIn() {
8182
>
8283
{feature.description}
8384
</p>
85+
{feature.id === 3 && (
86+
<div className="mt-6">
87+
<a href="/support">
88+
<Button
89+
shadowSize="4"
90+
className="bg-white px-6 py-3 text-base font-extrabold text-n-1 hover:bg-white/90"
91+
>
92+
Talk to Support
93+
</Button>
94+
</a>
95+
</div>
96+
)}
8497
</div>
8598
</div>
8699
))}

src/components/Profile/index.tsx

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -69,13 +69,14 @@ export const Profile = () => {
6969
endIcon={isKycApproved ? 'check' : undefined}
7070
endIconClassName={isKycApproved ? 'text-success-3 size-4' : undefined}
7171
/>
72-
<ProfileMenuItem
72+
{/* Enable with Account Management project. */}
73+
{/* <ProfileMenuItem
7374
icon="bank"
7475
label="Bank accounts"
7576
href="/profile/bank-accounts"
7677
position="middle"
7778
comingSoon
78-
/>
79+
/> */}
7980
<ProfileMenuItem icon="achievements" label="Achievements" position="last" comingSoon />
8081
</div>
8182
{/* Menu Items - Second Group */}

0 commit comments

Comments
 (0)