Skip to content

Commit

Permalink
chore: merge
Browse files Browse the repository at this point in the history
  • Loading branch information
LCJove committed Nov 15, 2024
2 parents 647a081 + c421ef3 commit eb7ea0c
Show file tree
Hide file tree
Showing 89 changed files with 1,556 additions and 1,105 deletions.
5 changes: 5 additions & 0 deletions .changeset/chilly-apricots-complain.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'@ant-design/web3': patch
---

fix: hide group when only one group
8 changes: 4 additions & 4 deletions .dumi/theme/builtins/HomePage/components/Features/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -20,16 +20,16 @@ export const Features: React.FC = () => {
{
preview:
curTheme.name === 'Dark'
? 'https://mdn.alipayobjects.com/huamei_mutawc/afts/img/A*q8CHTZn_t9cAAAAAAAAAAAAADlrGAQ/original'
: 'https://mdn.alipayobjects.com/huamei_mutawc/afts/img/A*BGOrT7hmCK0AAAAAAAAAAAAADlrGAQ/original',
? 'https://mdn.alipayobjects.com/huamei_mutawc/afts/img/A*c7xpS7iRaO0AAAAAAAAAAAAADlrGAQ/original'
: 'https://mdn.alipayobjects.com/huamei_mutawc/afts/img/A*lg4mQrmwvQMAAAAAAAAAAAAADlrGAQ/original',
title: intl.formatMessage({ id: 'app.docs.site.features.0.title' }),
description: intl.formatMessage({ id: 'app.docs.site.features.0.description' }),
},
{
preview:
curTheme.name === 'Dark'
? 'https://mdn.alipayobjects.com/huamei_mutawc/afts/img/A*c7xpS7iRaO0AAAAAAAAAAAAADlrGAQ/original'
: 'https://mdn.alipayobjects.com/huamei_mutawc/afts/img/A*lg4mQrmwvQMAAAAAAAAAAAAADlrGAQ/original',
? 'https://mdn.alipayobjects.com/huamei_mutawc/afts/img/A*q8CHTZn_t9cAAAAAAAAAAAAADlrGAQ/original'
: 'https://mdn.alipayobjects.com/huamei_mutawc/afts/img/A*BGOrT7hmCK0AAAAAAAAAAAAADlrGAQ/original',
title: intl.formatMessage({ id: 'app.docs.site.features.1.title' }),
description: intl.formatMessage({ id: 'app.docs.site.features.1.description' }),
},
Expand Down
18 changes: 1 addition & 17 deletions .dumi/theme/builtins/ThemeEditorPage/demos/address.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,36 +2,20 @@ import React from 'react';
import type { ComponentDemo } from 'antd-token-previewer-web3';

export const components: Record<string, string[]> = {
Address: ['Basic Address', 'Copyable', 'Custom Tooltip', 'Format'],
Address: ['Basic Address', 'Copyable'],
};

export const demos: Record<string, ComponentDemo[]> = {
'Basic Address': [
{
demo: React.createElement(require('@ant-design/web3/address/demos/basic').default),
tokens: [],
key: 'Basic Address',
},
],
Copyable: [
{
demo: React.createElement(require('@ant-design/web3/address/demos/copyable').default),
tokens: [],
key: 'Copyable',
},
],
'Custom Tooltip': [
{
demo: React.createElement(require('@ant-design/web3/address/demos/customTooltip').default),
tokens: [],
key: 'Custom Tooltip',
},
],
Format: [
{
demo: React.createElement(require('@ant-design/web3/address/demos/format').default),
tokens: [],
key: 'Format',
},
],
};
18 changes: 1 addition & 17 deletions .dumi/theme/builtins/ThemeEditorPage/demos/browser-link.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,35 +2,19 @@ import React from 'react';
import type { ComponentDemo } from 'antd-token-previewer-web3';

export const components: Record<string, string[]> = {
'Browser Link': ['Basic Browser Link', 'Complex', 'Custom Name', 'Icon Only'],
'Browser Link': ['Basic Browser Link', 'Icon Only'],
};

export const demos: Record<string, ComponentDemo[]> = {
'Basic Browser Link': [
{
demo: React.createElement(require('@ant-design/web3/browser-link/demos/basic').default),
tokens: [],
key: 'Basic Browser Link',
},
],
Complex: [
{
demo: React.createElement(require('@ant-design/web3/browser-link/demos/complex').default),
tokens: [],
key: 'Complex',
},
],
'Custom Name': [
{
demo: React.createElement(require('@ant-design/web3/browser-link/demos/customName').default),
tokens: [],
key: 'Custom Name',
},
],
'Icon Only': [
{
demo: React.createElement(require('@ant-design/web3/browser-link/demos/icononly').default),
tokens: [],
key: 'Icon Only',
},
],
Expand Down
77 changes: 1 addition & 76 deletions .dumi/theme/builtins/ThemeEditorPage/demos/connect-button.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,101 +2,26 @@ import React from 'react';
import type { ComponentDemo } from 'antd-token-previewer-web3';

export const components: Record<string, string[]> = {
'Connect Button': [
'Avatar',
'Balance',
'Basic',
'Chains',
'Icon',
'Menu',
'Name',
'Profile Modal',
'Quick Connect',
'Tooltip',
'Type',
],
'Connect Button': ['Avatar', 'Balance', 'Chains'],
};

export const demos: Record<string, ComponentDemo[]> = {
Avatar: [
{
demo: React.createElement(require('@ant-design/web3/connect-button/demos/avatar').default),
tokens: [],
key: 'Avatar',
},
],
Balance: [
{
demo: React.createElement(require('@ant-design/web3/connect-button/demos/balance').default),
tokens: [],
key: 'Balance',
},
],
Basic: [
{
demo: React.createElement(require('@ant-design/web3/connect-button/demos/basic').default),
tokens: [],
key: 'Basic',
},
],
Chains: [
{
demo: React.createElement(require('@ant-design/web3/connect-button/demos/chains').default),
tokens: [],
key: 'Chains',
},
],
Icon: [
{
demo: React.createElement(require('@ant-design/web3/connect-button/demos/icon').default),
tokens: [],
key: 'Icon',
},
],
Menu: [
{
demo: React.createElement(require('@ant-design/web3/connect-button/demos/menu').default),
tokens: [],
key: 'Menu',
},
],
Name: [
{
demo: React.createElement(require('@ant-design/web3/connect-button/demos/name').default),
tokens: [],
key: 'Name',
},
],
'Profile Modal': [
{
demo: React.createElement(
require('@ant-design/web3/connect-button/demos/profileModal').default,
),
tokens: [],
key: 'Profile Modal',
},
],
'Quick Connect': [
{
demo: React.createElement(
require('@ant-design/web3/connect-button/demos/quick-connect').default,
),
tokens: [],
key: 'Quick Connect',
},
],
Tooltip: [
{
demo: React.createElement(require('@ant-design/web3/connect-button/demos/tooltip').default),
tokens: [],
key: 'Tooltip',
},
],
Type: [
{
demo: React.createElement(require('@ant-design/web3/connect-button/demos/type').default),
tokens: [],
key: 'Type',
},
],
};
55 changes: 3 additions & 52 deletions .dumi/theme/builtins/ThemeEditorPage/demos/connect-modal.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,69 +2,20 @@ import React from 'react';
import type { ComponentDemo } from 'antd-token-previewer-web3';

export const components: Record<string, string[]> = {
'Connect Modal': [
'Basic Connect Modal',
'Custom Guide',
'Dark Mode',
'Panel',
'Simple',
'Theme',
'Ungrouped Basic',
],
'Connect Modal': ['Normal', 'Simple'],
};

export const demos: Record<string, ComponentDemo[]> = {
'Basic Connect Modal': [
{
demo: React.createElement(require('@ant-design/web3/connect-modal/demos/basic').default),
tokens: [],
key: 'Basic Connect Modal',
},
],
'Custom Guide': [
{
demo: React.createElement(
require('@ant-design/web3/connect-modal/demos/customGuide').default,
),
tokens: [],
key: 'Custom Guide',
},
],
'Dark Mode': [
{
demo: React.createElement(require('@ant-design/web3/connect-modal/demos/dark').default),
tokens: [],
key: 'Dark Mode',
},
],
Panel: [
Normal: [
{
demo: React.createElement(require('@ant-design/web3/connect-modal/demos/panel').default),
tokens: [],
key: 'Panel',
},
],
Simple: [
{
demo: React.createElement(require('@ant-design/web3/connect-modal/demos/simple').default),
tokens: [],
demo: React.createElement(require('@ant-design/web3/connect-modal/demos/panel').SimpleApp),
key: 'Simple',
},
],
Theme: [
{
demo: React.createElement(require('@ant-design/web3/connect-modal/demos/theme').default),
tokens: [],
key: 'Theme',
},
],
'Ungrouped Basic': [
{
demo: React.createElement(
require('@ant-design/web3/connect-modal/demos/ungroupedBasic').default,
),
tokens: [],
key: 'Ungrouped Basic',
},
],
};
13 changes: 1 addition & 12 deletions .dumi/theme/builtins/ThemeEditorPage/demos/crypto-price.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,30 +2,19 @@ import React from 'react';
import type { ComponentDemo } from 'antd-token-previewer-web3';

export const components: Record<string, string[]> = {
'Crypto Price': ['Basic Crypto Price', 'Custom Chains', 'With Icon'],
'Crypto Price': ['Basic Crypto Price', 'With Icon'],
};

export const demos: Record<string, ComponentDemo[]> = {
'Basic Crypto Price': [
{
demo: React.createElement(require('@ant-design/web3/crypto-price/demos/basic').default),
tokens: [],
key: 'Basic Crypto Price',
},
],
'Custom Chains': [
{
demo: React.createElement(
require('@ant-design/web3/crypto-price/demos/custom-chain').default,
),
tokens: [],
key: 'Custom Chains',
},
],
'With Icon': [
{
demo: React.createElement(require('@ant-design/web3/crypto-price/demos/icon').default),
tokens: [],
key: 'With Icon',
},
],
Expand Down
6 changes: 3 additions & 3 deletions .dumi/theme/builtins/ThemeEditorPage/demos/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,19 +8,19 @@ import * as cryptoPrice from './crypto-price';
import * as nftCard from './nft-card';

export const components: typeof defaultAntdComponents = {
...connectModal.components,
...nftCard.components,
...address.components,
...browserLink.components,
...connectButton.components,
...connectModal.components,
...cryptoPrice.components,
...nftCard.components,
};

export const demos: Record<string, ComponentDemo[]> = {
...connectModal.demos,
...address.demos,
...browserLink.demos,
...connectButton.demos,
...connectModal.demos,
...cryptoPrice.demos,
...nftCard.demos,
};
16 changes: 1 addition & 15 deletions .dumi/theme/builtins/ThemeEditorPage/demos/nft-card.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import React from 'react';
import type { ComponentDemo } from 'antd-token-previewer-web3';

export const components: Record<string, string[]> = {
'NFT Card': ['Basic NFT Card', 'Dark NFT', 'With Wagmi'],
'NFT Card': ['Basic NFT Card'],
};

export const demos: Record<string, ComponentDemo[]> = {
Expand All @@ -13,18 +13,4 @@ export const demos: Record<string, ComponentDemo[]> = {
key: 'Basic NFT Card',
},
],
'Dark NFT': [
{
demo: React.createElement(require('@ant-design/web3/nft-card/demos/dark-mode').default),
tokens: [],
key: 'Dark NFT',
},
],
'With Wagmi': [
{
demo: React.createElement(require('@ant-design/web3/nft-card/demos/wagmi').default),
tokens: [],
key: 'With Wagmi',
},
],
};
8 changes: 4 additions & 4 deletions .dumi/theme/locales/en-US.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,10 +11,10 @@
"app.docs.site.index.banner.slogan": "Efficient react components for building dapps easier",
"app.docs.site.index.banner.button-text": "Start",

"app.docs.site.features.0.title": "Ant Design Friendly",
"app.docs.site.features.0.description": "Ant Design Web3 is Specifically designed to seamlessly integrate with Ant Design, making it easy for developers.",
"app.docs.site.features.1.title": "Out-of-the-Box Experience",
"app.docs.site.features.1.description": "You can quickly set up their projects and leverage the pre-built components to create your DApps.",
"app.docs.site.features.0.title": "Out-of-the-Box Experience",
"app.docs.site.features.0.description": "You can quickly set up their projects and leverage the pre-built components to create your DApps.",
"app.docs.site.features.1.title": "Flexible Theme Customization",
"app.docs.site.features.1.description": "Provides powerful theme customization capabilities based on the Ant Design system.",
"app.docs.site.features.2.title": "Compatibility with Different Chains",
"app.docs.site.features.2.description": "Ant Design Web3 is designed with good extensibility, allowing you to adapt to different chains through adapters.",

Expand Down
8 changes: 4 additions & 4 deletions .dumi/theme/locales/zh-CN.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,10 +11,10 @@
"app.docs.site.index.banner.slogan": "高效的 React 组件库,更轻松地构建去中心化应用",
"app.docs.site.index.banner.button-text": "开始使用",

"app.docs.site.features.0.title": "Ant Design 友好",
"app.docs.site.features.0.description": "Ant Design Web3 的设计体系与 Ant Design 无缝衔接,开发者使用更容易",
"app.docs.site.features.1.title": "开箱即用的体验",
"app.docs.site.features.1.description": "你可以快速设置他们的项目,并利用预构建的组件来创建你的 DApps",
"app.docs.site.features.0.title": "开箱即用的体验",
"app.docs.site.features.0.description": "你可以快速设置他们的项目,并利用预构建的组件来创建你的 DApps",
"app.docs.site.features.1.title": "灵活的主题定制能力",
"app.docs.site.features.1.description": "基于 Ant Design 的设计体系提供强大的主题定制能力",
"app.docs.site.features.2.title": "与不同链的兼容性",
"app.docs.site.features.2.description": "Ant Design Web3 设计具有良好的扩展性,允许你通过适配器适应不同的链。",

Expand Down
Loading

0 comments on commit eb7ea0c

Please sign in to comment.