Skip to content

Commit 5c5466b

Browse files
committed
Added mantine, improved the bridge, gas, and token standards pages
1 parent a6552f6 commit 5c5466b

File tree

10 files changed

+258
-18171
lines changed

10 files changed

+258
-18171
lines changed

Diff for: package-lock.json

-18,142
This file was deleted.

Diff for: package.json

+4-1
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@
1010
},
1111
"license": "MIT",
1212
"dependencies": {
13+
"@mantine/hooks": "^7.10.0",
1314
"@mdx-js/loader": "^3.0.1",
1415
"@next/mdx": "^14.2.3",
1516
"@rainbow-me/rainbowkit": "^1.3.3",
@@ -31,7 +32,9 @@
3132
"devDependencies": {
3233
"@types/node": "18.11.10",
3334
"autoprefixer": "^10.4.17",
34-
"postcss": "^8.4.35",
35+
"postcss": "^8.4.38",
36+
"postcss-preset-mantine": "^1.15.0",
37+
"postcss-simple-vars": "^7.0.1",
3538
"tailwindcss": "^3.4.1",
3639
"typescript": "^5.3.3"
3740
}

Diff for: pages/_app.mdx

-12
This file was deleted.

Diff for: pages/_app.tsx

+21
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
import '../styles/globals.css';
2+
import '../styles/custom.css';
3+
import '@rainbow-me/rainbowkit/styles.css';
4+
import { ThemeProvider } from 'next-themes';
5+
import '@mantine/core/styles.css';
6+
import { createTheme, MantineProvider } from '@mantine/core';
7+
8+
const theme = createTheme({
9+
/** Put your mantine theme override here */
10+
});
11+
12+
export default function Nextra({ Component, pageProps }) {
13+
return (
14+
<MantineProvider theme={theme}>
15+
<ThemeProvider attribute="class">
16+
<Component {...pageProps} />
17+
</ThemeProvider>
18+
</MantineProvider>
19+
20+
);
21+
}

Diff for: pages/_document.tsx

+16
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
import { Head, Html, Main, NextScript } from 'next/document';
2+
import { ColorSchemeScript } from '@mantine/core';
3+
4+
export default function Document() {
5+
return (
6+
<Html lang="en">
7+
<Head>
8+
<ColorSchemeScript defaultColorScheme="auto" />
9+
</Head>
10+
<body>
11+
<Main />
12+
<NextScript />
13+
</body>
14+
</Html>
15+
);
16+
}

Diff for: pages/dev-ecosystem-providers/bridges.mdx

+7-3
Original file line numberDiff line numberDiff line change
@@ -4,16 +4,20 @@ Bridges facilitate cross-chain transfers and interoperability between different
44

55
## **Squid**:
66
Enables one-click cross-chain swaps across various EVM blockchains.
7-
- [Squid](https://app.squidrouter.com/)
7+
- [Squid](https://app.squidrouter.com)
88

99
## **Wormhole**:
1010
A popular bridge for transferring assets across multiple blockchains.
1111
- [Wormhole](https://wormholenetwork.com/)
1212

1313
## **Axelar**:
1414
Provides secure cross-chain communication for Web3.
15-
- [Axelar](https://axelar.network/)
15+
- [Axelar](https://axelar.network)
1616

1717
## **Stargate (coming soon)**:
1818
Facilitates seamless cross-chain transactions.
19-
- [Stargate](https://stargate.finance/)
19+
- [Stargate](https://stargate.finance)
20+
21+
## **IBC (Inter-Blockchain Communication)**:
22+
Enables interoperability between Cosmos-based blockchains, including Sei.
23+
- Learn more about [IBC Protocol](/dev-tutorials/ibc-protocol)

Diff for: pages/dev-gas.mdx

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# Gas on Sei
1+
# Gas
22

33
Gas refers to the unit of measurement representing the work done to execute a transaction on the blockchain. The amount of gas used varies based on the complexity of the transaction.
44

Diff for: pages/dev-token-standards.mdx

+36-5
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
In this section, we will delve into the various token standards supported on the Sei blockchain. Understanding these standards is crucial for developers as they form the foundation of many decentralized applications. Sei offers support for native TokenFactory tokens, ERC standards, CW standards, IBC and facilitates interoperability between these token types.
44

5-
### Sei Token
5+
## Sei Token
66

77
The Sei token is the native token of the Sei blockchain, serving multiple roles within the ecosystem.
88

@@ -15,22 +15,31 @@ The Sei token is the native token of the Sei blockchain, serving multiple roles
1515

1616
On the Cosmos side, the Sei token has 6 decimals, while on the EVM side, it follows the standard 18 decimals.
1717

18-
### TokenFactory
18+
#### EVM:
19+
`1sei = 1000000000000000000wei`
20+
`1sei = 1000000000gwei`
21+
22+
#### Cosmos:
23+
`1sei = 1000000usei`
24+
25+
## TokenFactory
1926

2027
TokenFactory allows for the creation of tokens that are natively integrated into the bank module of the Cosmos SDK. This integration means balances are available through native bank queries, unlike CW20 or ERC20 tokens which require querying the smart contract directly.
2128

2229
- **Why is it Recommended?**: It provides a more efficient way to manage tokens, leveraging the native capabilities of the Cosmos SDK for improved performance and ease of use.
2330
- **How to Create via `seid` CLI**: Tokens can be created using the `seid` command-line interface.
2431

25-
### Inter-Blockchain Communication (IBC)
32+
Learn more about creating tokens using TokenFactory in the [TokenFactory Tutorial](/dev-tutorials/tokenfactory-tutorial).
33+
34+
## Inter-Blockchain Communication (IBC)
2635

2736
IBC is a protocol that enables communication and asset transfers between different cosmos chains, enhancing interoperability and enabling cross-chain applications and liquidity.
2837

2938
- **Channel Info List**: Channels are used to establish communication paths between blockchains. Each channel has a unique identifier and specific configurations.
3039
- [IBC Channel Info Registry](https://github.com/sei-protocol/chain-registry/blob/main/ibc_info.json)
3140
- **Contributing to the IBC Registry**: IBC relayers can add new channels by making pull requests to the IBC registry.
3241

33-
### Fungible Tokens
42+
## Fungible Tokens
3443

3544
Fungible tokens are digital assets that are interchangeable with one another and are not unique. Sei supports both ERC20 and CW20 fungible token standards.
3645

@@ -40,7 +49,7 @@ Fungible tokens are digital assets that are interchangeable with one another and
4049
- [Pointer Contracts Documentation](/dev-tutorials/pointer-contracts)
4150
- **Pointer Contract Registry**: A registry that keeps track of pointer contracts to facilitate interoperability.
4251

43-
### NFTs
52+
## NFTs
4453

4554
Non-fungible tokens (NFTs) represent unique digital assets. Sei supports both ERC721 and CW721 standards as well as their counterparts with royalties (2981).
4655

@@ -49,3 +58,25 @@ Non-fungible tokens (NFTs) represent unique digital assets. Sei supports both ER
4958
- **Interoperability**: Similar to fungible tokens, NFTs can interact across different standards using pointer contracts.
5059
- **Pointer Contract Registry**: A registry for tracking pointer contracts specific to NFTs.
5160
- **CW2981 & ERC2981 (Royalties)**: These standards define royalty mechanisms for NFTs, ensuring creators receive a percentage of sales.
61+
62+
## Deciding Between TokenFactory vs CW20 or ERC20
63+
64+
When developing fungible tokens on the Sei blockchain, you have the option to create tokens using the native TokenFactory or the CW20 and ERC20 standards. Here’s a comparison to help you decide:
65+
66+
#### TokenFactory
67+
Best for native Cosmos applications requiring efficient and fast access to token balances and transactions.
68+
69+
- **Native Integration**: Tokens created via TokenFactory are integrated into the Cosmos SDK’s bank module.
70+
- **Efficient Queries**: Balances and transactions are available through native bank queries, making it more efficient than querying smart contracts directly.
71+
- **Recommended Use**: Ideal for scenarios where performance and ease of access are priorities.
72+
73+
#### CW20 and ERC20
74+
Suitable for applications needing standard token interactions for use with existing dApps and cross-vm interoperability.
75+
76+
- **Standard Compatibility**: CW20 for Cosmos and ERC20 for EVM ensure compatibility with existing dApps and ecosystems.
77+
- **Interoperability**: Both standards support pointer contracts, enabling seamless interaction between Cosmos and EVM environments.
78+
79+
#### Interoperability
80+
Regardless of the choice, both TokenFactory and CW20/ERC20 tokens can have pointer contracts deployed, facilitating seamless cross-environment interoperability.
81+
82+
For more detailed guidance, refer to the [Pointer Contracts Documentation](/dev-tutorials/pointer-contracts).

Diff for: postcss.config.js

+10
Original file line numberDiff line numberDiff line change
@@ -2,5 +2,15 @@ module.exports = {
22
plugins: {
33
tailwindcss: {},
44
autoprefixer: {},
5+
'postcss-preset-mantine': {},
6+
'postcss-simple-vars': {
7+
variables: {
8+
'mantine-breakpoint-xs': '36em',
9+
'mantine-breakpoint-sm': '48em',
10+
'mantine-breakpoint-md': '62em',
11+
'mantine-breakpoint-lg': '75em',
12+
'mantine-breakpoint-xl': '88em',
13+
},
14+
},
515
},
616
}

0 commit comments

Comments
 (0)