From 86d17630cd331432a94869cd10fe6b433c908906 Mon Sep 17 00:00:00 2001 From: Tron Date: Mon, 21 Jul 2025 14:01:50 +0800 Subject: [PATCH 1/7] fix some bugs --- docs/dapp/index.en.md | 53 ------------------- docs/dapp/index.zh.md | 53 ------------------- docs/dapp/stake2.en.md | 2 +- docs/dapp/stake2.zh.md | 4 +- docs/javascripts/nav-toc.js | 14 +++++ docs/mobile/asset-management.en.md | 1 - docs/mobile/asset-management.zh.md | 1 - docs/mobile/dapp-support.en.md | 1 - .../dapp-support/integrate-tronlink.en.md | 2 +- docs/mobile/deeplink.en.md | 8 ++- docs/mobile/deeplink.zh.md | 7 ++- docs/mobile/deeplink/callback-codes.en.md | 3 +- docs/mobile/deeplink/callback-codes.zh.md | 1 + docs/mobile/deeplink/login-auth.en.md | 1 - docs/mobile/index.en.md | 35 ------------ docs/mobile/index.zh.md | 35 ------------ docs/overrides/main.html | 32 +++++++++-- .../active-requests/connect-website.en.md | 7 +-- docs/plugin-wallet/index.en.md | 36 ------------- docs/plugin-wallet/index.zh.md | 36 ------------- .../passive-messages/account-change.zh.md | 1 - .../user-active-connect.zh.md | 2 +- docs/stylesheets/extra.css | 44 +++++++++++++++ mkdocs.yml | 8 +-- 24 files changed, 112 insertions(+), 275 deletions(-) delete mode 100644 docs/dapp/index.en.md delete mode 100644 docs/dapp/index.zh.md delete mode 100644 docs/mobile/index.en.md delete mode 100644 docs/mobile/index.zh.md delete mode 100644 docs/plugin-wallet/index.en.md delete mode 100644 docs/plugin-wallet/index.zh.md diff --git a/docs/dapp/index.en.md b/docs/dapp/index.en.md deleted file mode 100644 index 4148688..0000000 --- a/docs/dapp/index.en.md +++ /dev/null @@ -1,53 +0,0 @@ -# DApp 开发指南 - -TronLink 为 DApp 开发者提供了完整的开发工具和 API,支持多签转账、消息签名、普通转账和 Stake2.0 等功能。 - -## 主要功能 - -### 基础功能 -- [开始开发](getting-started.md) - DApp 开发快速开始指南 -- [普通转账](transfer.md) - 基本的转账功能 - -### 高级功能 -- [多签转账](multi-sign-transfer.md) - 多签转账功能实现 -- [消息签名](message-signing.md) - 消息签名功能 -- [Stake2.0](stake2.md) - Stake2.0 功能集成 - -## 开发流程 - -### 1. 环境准备 -- 安装 TronLink 钱包 -- 配置开发环境 -- 准备测试网络 - -### 2. 基础集成 -- 按照 [开始开发](getting-started.md) 进行基础集成 -- 实现基本的转账功能 -- 测试基础功能 - -### 3. 高级功能 -- 根据需求集成多签转账 -- 实现消息签名功能 -- 集成 Stake2.0 功能 - -### 4. 测试和部署 -- 全面测试所有功能 -- 优化用户体验 -- 部署到生产环境 - -## 最佳实践 - -- 始终在测试网络进行充分测试 -- 实现错误处理和用户提示 -- 遵循安全最佳实践 -- 提供清晰的用户界面和操作指引 - -## 技术支持 - -- 参考相关文档进行开发 -- 加入开发者社区获取帮助 -- 联系技术支持团队解决技术问题 - -## 示例代码 - -每个功能模块都提供了详细的示例代码,开发者可以直接参考使用。 \ No newline at end of file diff --git a/docs/dapp/index.zh.md b/docs/dapp/index.zh.md deleted file mode 100644 index 4148688..0000000 --- a/docs/dapp/index.zh.md +++ /dev/null @@ -1,53 +0,0 @@ -# DApp 开发指南 - -TronLink 为 DApp 开发者提供了完整的开发工具和 API,支持多签转账、消息签名、普通转账和 Stake2.0 等功能。 - -## 主要功能 - -### 基础功能 -- [开始开发](getting-started.md) - DApp 开发快速开始指南 -- [普通转账](transfer.md) - 基本的转账功能 - -### 高级功能 -- [多签转账](multi-sign-transfer.md) - 多签转账功能实现 -- [消息签名](message-signing.md) - 消息签名功能 -- [Stake2.0](stake2.md) - Stake2.0 功能集成 - -## 开发流程 - -### 1. 环境准备 -- 安装 TronLink 钱包 -- 配置开发环境 -- 准备测试网络 - -### 2. 基础集成 -- 按照 [开始开发](getting-started.md) 进行基础集成 -- 实现基本的转账功能 -- 测试基础功能 - -### 3. 高级功能 -- 根据需求集成多签转账 -- 实现消息签名功能 -- 集成 Stake2.0 功能 - -### 4. 测试和部署 -- 全面测试所有功能 -- 优化用户体验 -- 部署到生产环境 - -## 最佳实践 - -- 始终在测试网络进行充分测试 -- 实现错误处理和用户提示 -- 遵循安全最佳实践 -- 提供清晰的用户界面和操作指引 - -## 技术支持 - -- 参考相关文档进行开发 -- 加入开发者社区获取帮助 -- 联系技术支持团队解决技术问题 - -## 示例代码 - -每个功能模块都提供了详细的示例代码,开发者可以直接参考使用。 \ No newline at end of file diff --git a/docs/dapp/stake2.en.md b/docs/dapp/stake2.en.md index c7edca0..8634ef8 100644 --- a/docs/dapp/stake2.en.md +++ b/docs/dapp/stake2.en.md @@ -24,5 +24,5 @@ For example: transaction.__options = {"estimatedBandwidth": 1} ``` -The specific calculation logic of estimatedEnergy and estimatedBandwidth can be found in the last chapter of the "[Stake 2.0 Adaptation FAQ](https://coredevs.medium.com/stake-2-0-adaption-faq-66bafdf53606)": "How to convert resource share to amount?" +The specific calculation logic of estimatedEnergy and estimatedBandwidth can be found in the last chapter of the "[Stake 2.0 Adaptation FAQ](https://coredevs.medium.com/stake-2-0-adaption-faq-66bafdf53606)": "How to convert resource share to amount?" diff --git a/docs/dapp/stake2.zh.md b/docs/dapp/stake2.zh.md index 8aa21de..27d20e8 100644 --- a/docs/dapp/stake2.zh.md +++ b/docs/dapp/stake2.zh.md @@ -23,6 +23,4 @@ img { transaction.__options = {"estimatedBandwidth": 1} ``` -estimatedEnergy estimatedBandwidth 的具体计算逻辑见![image](../images/dapp_skake2.0_img_1.png)[Stake 2.0 Adaption FAQ](https://www.google.com/url?q=https://coredevs.medium.com/stake-2-0-adaption-faq-66bafdf53606&sa=D&source=editors&ust=1684151119972747&usg=AOvVaw0msvWulJZhW6xn5QU461cb) 最后一个章节:How to convert resource share to amount? - - +estimatedEnergy estimatedBandwidth 的具体计算逻辑见![image](../images/dapp_skake2.0_img_1.png)[Stake 2.0 Adaptation FAQ](https://www.google.com/url?q=https://coredevs.medium.com/stake-2-0-adaption-faq-66bafdf53606&sa=D&source=editors&ust=1684151119972747&usg=AOvVaw0msvWulJZhW6xn5QU461cb) 最后一个章节:How to convert resource share to amount? diff --git a/docs/javascripts/nav-toc.js b/docs/javascripts/nav-toc.js index 4f49072..a6a10b6 100644 --- a/docs/javascripts/nav-toc.js +++ b/docs/javascripts/nav-toc.js @@ -41,4 +41,18 @@ document.addEventListener("DOMContentLoaded", function () { console.error("tocLink not found"); } } + + + + const header = document.querySelector(".md-header__inner"); // 找到导航容器 + if (header) { + const a1 = document.createElement("a"); + a1.href = "https://www.tronlink.org/"; + a1.target = "_blank"; + a1.className = "md-header__link"; + a1.style="font-size:14px"; + a1.textContent = "Homepage"; + + header.appendChild(a1); + } }); diff --git a/docs/mobile/asset-management.en.md b/docs/mobile/asset-management.en.md index 696d6f9..6ea970b 100644 --- a/docs/mobile/asset-management.en.md +++ b/docs/mobile/asset-management.en.md @@ -1,4 +1,3 @@ - # Asset Management
diff --git a/docs/mobile/asset-management.zh.md b/docs/mobile/asset-management.zh.md index c39de4c..0de0712 100644 --- a/docs/mobile/asset-management.zh.md +++ b/docs/mobile/asset-management.zh.md @@ -1,4 +1,3 @@ - # 资产管理 管理您的资产,并支持自定义通证 diff --git a/docs/mobile/dapp-support.en.md b/docs/mobile/dapp-support.en.md index f40dfb1..dae2cc1 100644 --- a/docs/mobile/dapp-support.en.md +++ b/docs/mobile/dapp-support.en.md @@ -1,4 +1,3 @@ - # DApp Support
diff --git a/docs/mobile/dapp-support/integrate-tronlink.en.md b/docs/mobile/dapp-support/integrate-tronlink.en.md index 74abe72..88cbfb7 100644 --- a/docs/mobile/dapp-support/integrate-tronlink.en.md +++ b/docs/mobile/dapp-support/integrate-tronlink.en.md @@ -2,4 +2,4 @@ TronLink injects a version of TronWeb into the DApp that runs in TronLink's DApp Explorer. This enables the DApp to interact with TronLink DApps and the TRON network. -Details: Go to DApp +Details: [Go to DApp](../../dapp/getting-started.en.md) diff --git a/docs/mobile/deeplink.en.md b/docs/mobile/deeplink.en.md index 9b8aa9b..6724bb2 100644 --- a/docs/mobile/deeplink.en.md +++ b/docs/mobile/deeplink.en.md @@ -4,7 +4,13 @@ DApps and H5 pages can launch the TronLink App to open the wallet, log in, make ![image](../images/tronlink-app_deeplink_img_0.jpg) + + Process Flowchart -Please be aware that only dApps that have been added to the whitelist will be able to establish a successful connection with TronLink. Kindly fill out the whitelist request form here: [Start](https://docs.google.com/forms/d/e/1FAIpQLSdFmYGxVZzwCSsvmdOTq064sxWD22STYth1g5GO5zn3OrB5Jw/viewform?usp=sf_link) +Please be aware that only DApps that have been added to the whitelist will be able to establish a successful connection with TronLink. Kindly fill out the whitelist request form here: [Start](https://docs.google.com/forms/d/e/1FAIpQLSdFmYGxVZzwCSsvmdOTq064sxWD22STYth1g5GO5zn3OrB5Jw/viewform?usp=sf_link) diff --git a/docs/mobile/deeplink.zh.md b/docs/mobile/deeplink.zh.md index 9a3e92c..93ad5cb 100644 --- a/docs/mobile/deeplink.zh.md +++ b/docs/mobile/deeplink.zh.md @@ -3,9 +3,14 @@ DApp、H5应用可以使用 DeepLink 方式拉起 TronLink App 进行打开钱包,登录,转账,签名交易,字符串签名,在钱包中打开 DApp 等操作。 ![image](../images/zh_yi-dong-duan_deeplink_img_0.jpg) + 操作流程图 -注意:只有已添加至白名单的 dApp 才能成功连接至 TronLink。请在此处填写白名单申请:[填写表单](https://docs.google.com/forms/d/e/1FAIpQLSdFmYGxVZzwCSsvmdOTq064sxWD22STYth1g5GO5zn3OrB5Jw/viewform?usp=sf_link) +注意:只有已添加至白名单的 DApp 才能成功连接至 TronLink。请在此处填写白名单申请:[填写表单](https://docs.google.com/forms/d/e/1FAIpQLSdFmYGxVZzwCSsvmdOTq064sxWD22STYth1g5GO5zn3OrB5Jw/viewform?usp=sf_link) diff --git a/docs/mobile/deeplink/callback-codes.en.md b/docs/mobile/deeplink/callback-codes.en.md index a267282..7e217ba 100644 --- a/docs/mobile/deeplink/callback-codes.en.md +++ b/docs/mobile/deeplink/callback-codes.en.md @@ -1,7 +1,8 @@ # Result Code -| 0 | success | | +| id | Message | | |:-------|:-------|:-------| +| 0 | success | | | 10001 | Incorrect JSON format | | | 10002 | Missing Action | | | 10003 | Unknown Action | | diff --git a/docs/mobile/deeplink/callback-codes.zh.md b/docs/mobile/deeplink/callback-codes.zh.md index d7fe1da..3644e9b 100644 --- a/docs/mobile/deeplink/callback-codes.zh.md +++ b/docs/mobile/deeplink/callback-codes.zh.md @@ -2,6 +2,7 @@ | id | 消息 | 备注 | |:-------|:-------|:-------| +| 0 | success | | | 10001 | Incorrect JSON format | | | 10002 | Missing Action | | | 10003 | Unknown Action | | diff --git a/docs/mobile/deeplink/login-auth.en.md b/docs/mobile/deeplink/login-auth.en.md index 49dc0e8..625ae99 100644 --- a/docs/mobile/deeplink/login-auth.en.md +++ b/docs/mobile/deeplink/login-auth.en.md @@ -1,4 +1,3 @@ - # Login by TronLink ```shell diff --git a/docs/mobile/index.en.md b/docs/mobile/index.en.md deleted file mode 100644 index 5833969..0000000 --- a/docs/mobile/index.en.md +++ /dev/null @@ -1,35 +0,0 @@ -# 移动端开发 - -TronLink 移动端提供了完整的开发者集成方案,包括资产管理、DeepLink 集成和 DApp 浏览器支持。 - -## 主要功能 - -### 资产管理 -- [资产管理概述](asset-management.md) - 了解如何在移动端管理资产 -- [自定义通证](asset-management/custom-tokens.md) - 添加和管理自定义通证 - -### DeepLink 集成 -- [DeepLink 概述](deeplink.md) - DeepLink 功能总览 -- [打开钱包](deeplink/open-wallet.md) - 通过 DeepLink 打开钱包 -- [打开DApp](deeplink/open-dapp.md) - 通过 DeepLink 打开 DApp -- [登陆授权](deeplink/login-auth.md) - 用户登录和授权 -- [转账](deeplink/transfer.md) - 通过 DeepLink 进行转账 -- [交易签名](deeplink/transaction-signing.md) - 交易签名功能 -- [消息签名](deeplink/message-signing.md) - 消息签名功能 -- [回传消息码](deeplink/callback-codes.md) - 回传消息码说明 - -### DApp 支持 -- [DApp 支持概述](dapp-support.md) - DApp 集成总览 -- [集成TronLink](dapp-support/integrate-tronlink.md) - 如何集成 TronLink -- [DApp浏览器](dapp-support/dapp-browser.md) - DApp 浏览器功能 - -## 快速开始 - -1. 阅读 [DeepLink 概述](deeplink.md) 了解基本概念 -2. 按照 [集成TronLink](dapp-support/integrate-tronlink.md) 进行集成 -3. 测试各种功能,确保正常工作 -4. 参考示例代码进行开发 - -## 技术支持 - -如有问题,请参考相关文档或联系技术支持团队。 \ No newline at end of file diff --git a/docs/mobile/index.zh.md b/docs/mobile/index.zh.md deleted file mode 100644 index 5833969..0000000 --- a/docs/mobile/index.zh.md +++ /dev/null @@ -1,35 +0,0 @@ -# 移动端开发 - -TronLink 移动端提供了完整的开发者集成方案,包括资产管理、DeepLink 集成和 DApp 浏览器支持。 - -## 主要功能 - -### 资产管理 -- [资产管理概述](asset-management.md) - 了解如何在移动端管理资产 -- [自定义通证](asset-management/custom-tokens.md) - 添加和管理自定义通证 - -### DeepLink 集成 -- [DeepLink 概述](deeplink.md) - DeepLink 功能总览 -- [打开钱包](deeplink/open-wallet.md) - 通过 DeepLink 打开钱包 -- [打开DApp](deeplink/open-dapp.md) - 通过 DeepLink 打开 DApp -- [登陆授权](deeplink/login-auth.md) - 用户登录和授权 -- [转账](deeplink/transfer.md) - 通过 DeepLink 进行转账 -- [交易签名](deeplink/transaction-signing.md) - 交易签名功能 -- [消息签名](deeplink/message-signing.md) - 消息签名功能 -- [回传消息码](deeplink/callback-codes.md) - 回传消息码说明 - -### DApp 支持 -- [DApp 支持概述](dapp-support.md) - DApp 集成总览 -- [集成TronLink](dapp-support/integrate-tronlink.md) - 如何集成 TronLink -- [DApp浏览器](dapp-support/dapp-browser.md) - DApp 浏览器功能 - -## 快速开始 - -1. 阅读 [DeepLink 概述](deeplink.md) 了解基本概念 -2. 按照 [集成TronLink](dapp-support/integrate-tronlink.md) 进行集成 -3. 测试各种功能,确保正常工作 -4. 参考示例代码进行开发 - -## 技术支持 - -如有问题,请参考相关文档或联系技术支持团队。 \ No newline at end of file diff --git a/docs/overrides/main.html b/docs/overrides/main.html index 741d688..432b375 100644 --- a/docs/overrides/main.html +++ b/docs/overrides/main.html @@ -9,13 +9,37 @@