Skip to content

Commit f1eb091

Browse files
authored
Merge pull request #5 from Orbiton-labs/fix/connect-wallet-state
fix: connect wallet state
2 parents 6e0ec2a + 6cc3231 commit f1eb091

File tree

1 file changed

+9
-2
lines changed

1 file changed

+9
-2
lines changed

src/app/swap/page.tsx

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -125,7 +125,13 @@ export default function SwapPage() {
125125
canSwapOrder={true}
126126
disable1={true}
127127
/>
128-
<MemoDialog
128+
{status === SwapStatus.CONNECT_WALLET ? <SubmitButton
129+
onClick={async () => { await tonConnectUI.openModal() }}
130+
isLoading={false}
131+
isDisabled={isButtonDisabled()}
132+
error={error || undefined}
133+
content={buttonMessage}
134+
/> : <MemoDialog
129135
setMemo={setMemo}
130136
onSubmit={async () => {
131137
await swap();
@@ -145,7 +151,8 @@ export default function SwapPage() {
145151
isDisabled={isButtonDisabled()}
146152
error={error || undefined}
147153
content={buttonMessage}
148-
/>} />
154+
/>} />}
155+
149156

150157
</div>
151158
</div>

0 commit comments

Comments
 (0)