Skip to content

Commit 5af5fd8

Browse files
committed
chore: add One Bridge link
1 parent 4eb0d65 commit 5af5fd8

File tree

7 files changed

+70
-3
lines changed

7 files changed

+70
-3
lines changed

proposals/proposal-450.sh

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
#!/usr/bin/env bash
2+
3+
# Load the environment variables
4+
source "$(pwd)"/proposals/env.sh
5+
6+
# build and get batch_id, evidence:
7+
# dfx deploy ic_panda_frontend --ic --by-proposal
8+
9+
export BLOB="$(didc encode --format blob '(record {batch_id=81:nat; evidence=blob "\d0\32\47\70\64\c7\a8\15\db\d5\a4\7b\7c\74\8b\fc\f8\e2\f8\60\1a\47\8e\57\a2\45\8b\ce\10\cb\85\28"})')"
10+
11+
quill sns make-proposal --canister-ids-file ./sns_canister_ids.json --pem-file $PROPOSAL_PEM_FILE $PROPOSAL_NEURON_ID --proposal "(
12+
record {
13+
title = \"Execute commit_proposed_batch() to release ic_panda_frontend v2.13.6\";
14+
url = \"https://panda.fans/\";
15+
summary = \"This proposal executes commit_proposed_batch() on c63a7-6yaaa-aaaap-ab3gq-cai to release ic_panda_frontend v2.13.6.\n\n1. chore: add One Bridge link;\n2. chore: add BNB chain contract.\";
16+
action = opt variant {
17+
ExecuteGenericNervousSystemFunction = record {
18+
function_id = 1000 : nat64;
19+
payload = ${BLOB};
20+
}
21+
};
22+
}
23+
)" > proposal-message.json
24+
25+
# quill send proposal-message.json

src/ic_panda_frontend/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -78,5 +78,5 @@
7878
"test": "vitest run"
7979
},
8080
"type": "module",
81-
"version": "2.13.5"
81+
"version": "2.13.6"
8282
}

src/ic_panda_frontend/src/lib/components/core/PageFooter.svelte

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,5 +36,9 @@
3636
>
3737
<span class="mx-1">|</span>
3838
<a class="underline underline-offset-4" href="https://dmsg.net">dMsg.net</a>
39+
<span class="mx-1">|</span>
40+
<a class="underline underline-offset-4" href="https://1bridge.app"
41+
>One Bridge</a
42+
>
3943
</p>
4044
</div>

src/ic_panda_frontend/src/lib/components/core/PageHeader.svelte

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -65,6 +65,13 @@
6565
>
6666
Lucky Pool
6767
</TabAnchor>
68+
<TabAnchor
69+
href="https://1bridge.app/?token=PANDA&from=ICP&to=BNB"
70+
target="_blank"
71+
rel="noopener noreferrer"
72+
>
73+
Bridge
74+
</TabAnchor>
6875
<!-- <TabAnchor
6976
href="/_/airdrop"
7077
selected={page.url?.pathname.startsWith('/_/airdrop')}

src/ic_panda_frontend/src/lib/utils/helper.ts

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,4 +36,11 @@ export function getPriceNumber(v: number): string {
3636
return v.toFixed(2)
3737
}
3838
return v.toFixed(1)
39-
}
39+
}
40+
41+
export function pruneAddress(id: string, long?: boolean): string {
42+
if (long ?? window.innerWidth >= 640) {
43+
return id.length > 27 ? id.slice(0, 13) + '...' + id.slice(-11) : id
44+
}
45+
return id.length > 15 ? id.slice(0, 7) + '...' + id.slice(-5) : id
46+
}

src/ic_panda_frontend/src/routes/(app)/+page.svelte

Lines changed: 24 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
import IconX from '$lib/components/icons/IconX.svelte'
88
import Saos from '$lib/components/ui/Saos.svelte'
99
import { tokensPrice, type TokenPrice } from '$lib/stores/icpswap.svelte'
10-
import { getPriceNumber } from '$lib/utils/helper'
10+
import { getPriceNumber, pruneAddress } from '$lib/utils/helper'
1111
import { ICPToken, PANDAToken } from '$lib/utils/token'
1212
import { ConicGradient, getToastStore } from '@skeletonlabs/skeleton'
1313
import { onMount } from 'svelte'
@@ -212,6 +212,29 @@
212212
>
213213
<p class="text-2xl font-bold text-panda">1,080,000,000</p>
214214
</div>
215+
216+
<div class="space-y-2">
217+
<h3 class="text-sm uppercase tracking-wide text-gray/80"
218+
>Contracts</h3
219+
>
220+
<p class="text"
221+
>ICP Chain: <a
222+
class="underline decoration-1 underline-offset-4 transition-colors hover:text-primary-400"
223+
title="PANDA contract on ICP chain"
224+
href="https://dashboard.internetcomputer.org/canister/druyg-tyaaa-aaaaq-aactq-cai"
225+
target="_blank">{pruneAddress('druyg-tyaaa-aaaaq-aactq-cai')}</a
226+
></p
227+
>
228+
<p class="text"
229+
>BNB Chain: <a
230+
class="underline decoration-1 underline-offset-4 transition-colors hover:text-primary-400"
231+
title="PANDA contract on BNB chain"
232+
href="https://bscscan.com/token/0xe74583edaff618d88463554b84bc675196b36990"
233+
target="_blank"
234+
>{pruneAddress('0xe74583edAFF618D88463554b84Bc675196b36990')}</a
235+
></p
236+
>
237+
</div>
215238
</div>
216239
</div>
217240
</Saos>

src/ic_panda_frontend/static/_assets/logo_32.svg

Lines changed: 1 addition & 0 deletions
Loading

0 commit comments

Comments
 (0)