Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Darwinia USDT cross-chain #3

Merged
merged 106 commits into from
Nov 6, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
106 commits
Select commit Hold shift + click to select a range
e2f963c
Install prettier
JayJay1024 Oct 11, 2023
202b4a7
Prettier code
JayJay1024 Oct 11, 2023
34a1280
Install eslint-config-prettier
JayJay1024 Oct 11, 2023
900c4cb
Init husky
JayJay1024 Oct 11, 2023
8d0b9e4
Setup lint-staged
JayJay1024 Oct 11, 2023
190bef5
Tailwind prettier config
JayJay1024 Oct 19, 2023
9f65c46
Update tailwind config
JayJay1024 Oct 20, 2023
e3d135e
Install @polkadot/api
JayJay1024 Oct 23, 2023
c228ce1
Test cross
JayJay1024 Oct 26, 2023
2e68ab1
Asset type
JayJay1024 Oct 30, 2023
0101afc
Refactor chain config
JayJay1024 Oct 30, 2023
7d24d3e
Connfigure cross
JayJay1024 Oct 30, 2023
6746c51
Chain utils
JayJay1024 Oct 30, 2023
da3e7d2
Configure cross wallet
JayJay1024 Oct 30, 2023
28d25a8
Configure global styles
JayJay1024 Oct 30, 2023
3ee0287
Update root layout
JayJay1024 Oct 30, 2023
bad17f1
Add app icon.svg
JayJay1024 Oct 30, 2023
863b686
PageWrap component
JayJay1024 Oct 30, 2023
25ac134
Create header and footer
JayJay1024 Oct 30, 2023
a0bedfd
Update root layout
JayJay1024 Oct 30, 2023
a9781ce
Update header logo
JayJay1024 Oct 30, 2023
b9305dc
Bridge lib
JayJay1024 Oct 30, 2023
97a46d2
Create balance utils
JayJay1024 Oct 31, 2023
8dc95b6
Talisman provider
JayJay1024 Oct 31, 2023
e66d193
Hook useTalisman
JayJay1024 Oct 31, 2023
a65e27f
New formatBalance util
JayJay1024 Oct 31, 2023
3f249e8
Rename to getNativeBalance
JayJay1024 Oct 31, 2023
25f0cc4
Update test page
JayJay1024 Oct 31, 2023
59af6c8
Configure parachain id
JayJay1024 Oct 31, 2023
9231477
Improve bridge lib
JayJay1024 Oct 31, 2023
67d3e71
Remove getBalance from balance util
JayJay1024 Oct 31, 2023
d4d3353
Improve return value of getBalance
JayJay1024 Oct 31, 2023
8e0346b
Configure isReserve
JayJay1024 Oct 31, 2023
c163065
Update Asset type
JayJay1024 Oct 31, 2023
c97af0d
Improve bridge lib
JayJay1024 Oct 31, 2023
2e9d051
Talisman provider activeAccount
JayJay1024 Oct 31, 2023
768d54f
New Transfer provider
JayJay1024 Oct 31, 2023
631322a
Hook useTransfer
JayJay1024 Oct 31, 2023
59451ed
New notification ui
JayJay1024 Oct 31, 2023
726eff2
Notify extrinsic and transaction
JayJay1024 Oct 31, 2023
d82888e
Hook useApi
JayJay1024 Oct 31, 2023
f70eb87
Hook useBalance
JayJay1024 Oct 31, 2023
66dd4f1
Support refetch for useBalance
JayJay1024 Oct 31, 2023
4e4c177
Fetch source and target balance
JayJay1024 Oct 31, 2023
6df1da6
Transfer callback
JayJay1024 Oct 31, 2023
667511e
Button ui
JayJay1024 Oct 31, 2023
70a36e4
Split to sourceChain sourceAsset targetChain and targetAsset
JayJay1024 Nov 2, 2023
c4af50f
Fix build failed
JayJay1024 Nov 2, 2023
b4b60fd
Hook useToggle
JayJay1024 Nov 2, 2023
28847ff
Dropdown ui
JayJay1024 Nov 2, 2023
6bd11a4
Select ui
JayJay1024 Nov 3, 2023
5b76ffc
Modal ui
JayJay1024 Nov 3, 2023
c05e377
CopyIcon ui
JayJay1024 Nov 3, 2023
f4b8215
Loading ui
JayJay1024 Nov 3, 2023
50b0e46
Input ui
JayJay1024 Nov 3, 2023
cdd5ec9
Tooltip ui
JayJay1024 Nov 3, 2023
5945ef2
Cross utils
JayJay1024 Nov 3, 2023
0aa1a4c
Configure chain logo and asset icon
JayJay1024 Nov 3, 2023
31c486a
Utils getChainLogoSrc and getAssetIconSrc
JayJay1024 Nov 3, 2023
2b97577
AssetSelect component
JayJay1024 Nov 3, 2023
5b459a3
BalanceInput component
JayJay1024 Nov 3, 2023
d33ca77
SwitchCross component
JayJay1024 Nov 3, 2023
eb3b789
ChainSelect component
JayJay1024 Nov 3, 2023
8a9f510
ConnectWallet component
JayJay1024 Nov 3, 2023
29d1b1a
AddressSelect component
JayJay1024 Nov 3, 2023
8357520
Label component
JayJay1024 Nov 3, 2023
54dfd2c
Fix dev console warning
JayJay1024 Nov 3, 2023
aa3a04a
TransferSection component
JayJay1024 Nov 3, 2023
159080e
Improve Select with suffix props
JayJay1024 Nov 5, 2023
6f5dfa6
Update Label text color
JayJay1024 Nov 5, 2023
f305b67
Support disconnect talisman wallet
JayJay1024 Nov 5, 2023
5d0c78a
Support innerSuffix of Select
JayJay1024 Nov 5, 2023
07838e7
AddressInput component
JayJay1024 Nov 5, 2023
aeeb6e1
Talisman provider update activeAccount
JayJay1024 Nov 5, 2023
e3f1e15
ConnectWallet component
JayJay1024 Nov 5, 2023
cf77814
Update border radius
JayJay1024 Nov 5, 2023
ae78091
Improve transfer provider default value
JayJay1024 Nov 5, 2023
71dbc70
Button component kind
JayJay1024 Nov 5, 2023
ce1dcce
Modal stopPropagation for mask click
JayJay1024 Nov 5, 2023
5dcf922
Root layout import talisman and transfer providers
JayJay1024 Nov 5, 2023
eb2bdca
Fix disconnect for ConnectWallet
JayJay1024 Nov 5, 2023
51c6cac
Fix default kind border color of Button
JayJay1024 Nov 5, 2023
9720ae5
Fix useBalance
JayJay1024 Nov 5, 2023
58f5eba
Tailwind content include utils tsx file
JayJay1024 Nov 5, 2023
caf5b73
Fix Tooltip border color
JayJay1024 Nov 5, 2023
77a614b
Fix AddressInput value
JayJay1024 Nov 5, 2023
84d1951
Improve AssetSelect
JayJay1024 Nov 5, 2023
bd637dc
Improve AddressSelect
JayJay1024 Nov 5, 2023
7cc8c5e
Improve BalanceInput
JayJay1024 Nov 5, 2023
6719117
Improve ChainSelect
JayJay1024 Nov 5, 2023
5d5be99
Improve ConnectWallet
JayJay1024 Nov 5, 2023
6db2c6f
Improve SwitchCross
JayJay1024 Nov 5, 2023
db08a58
Update label text color
JayJay1024 Nov 5, 2023
2c60b29
Improve TransferSelect
JayJay1024 Nov 5, 2023
37630a2
Fix transfer provider
JayJay1024 Nov 5, 2023
4c79a76
Update defaultSourceChainOptions
JayJay1024 Nov 5, 2023
7d10b56
Select arrowClassName
JayJay1024 Nov 5, 2023
c4ced21
Transfer component
JayJay1024 Nov 5, 2023
501ead6
Page import Transfer
JayJay1024 Nov 5, 2023
045c1e3
Improve footer
JayJay1024 Nov 5, 2023
8c84993
Support kind for ConnectWallet
JayJay1024 Nov 5, 2023
eb4b3e8
ConnectWallet use client
JayJay1024 Nov 5, 2023
756160a
ConnectWallet hover cursor-pointer
JayJay1024 Nov 5, 2023
6283109
Improve header
JayJay1024 Nov 5, 2023
82bde84
Fix border radius of Modal
JayJay1024 Nov 5, 2023
e2cadb4
Improve theme rainbowkit provider
JayJay1024 Nov 5, 2023
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .env
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
NEXT_PUBLIC_WALLET_CONNECT_ID=2719448e2ce94fdd269a3c8587123bcc
2 changes: 1 addition & 1 deletion .eslintrc.json
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
{
"extends": "next/core-web-vitals"
"extends": ["next/core-web-vitals", "prettier"]
}
4 changes: 4 additions & 0 deletions .husky/pre-commit
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
#!/usr/bin/env sh
. "$(dirname -- "$0")/_/husky.sh"

npx lint-staged
9 changes: 9 additions & 0 deletions .lintstagedrc.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
const path = require("path");

const buildEslintCommand = (filenames) =>
`next lint --fix --file ${filenames.map((f) => path.relative(process.cwd(), f)).join(" --file ")}`;

module.exports = {
"src/**/*.{js,jsx,ts,tsx}": [buildEslintCommand],
"src/**/*.{js,jsx,ts,tsx,json}": "prettier --write",
};
4 changes: 4 additions & 0 deletions .prettierrc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
{
"printWidth": 120,
"plugins": ["prettier-plugin-tailwindcss"]
}
9 changes: 7 additions & 2 deletions next.config.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,9 @@
/** @type {import('next').NextConfig} */
const nextConfig = {}
const nextConfig = {
webpack: (config) => {
config.externals.push("lokijs", "encoding", "pino-pretty");
return config;
},
};

module.exports = nextConfig
module.exports = nextConfig;
Loading