From a37ae407cd1a79d2a76a4888c4aee605c47d826e Mon Sep 17 00:00:00 2001 From: weixin_47469434 Date: Wed, 13 Aug 2025 17:42:38 +0800 Subject: [PATCH] =?UTF-8?q?docs:=20[Issues:#ICST79]=20=E6=B7=BB=E5=8A=A00.?= =?UTF-8?q?77=202=E4=B8=AA=E4=B8=89=E6=96=B9=E5=BA=93=E6=96=87=E6=A1=A3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: weixin_47469434 --- zh-cn/react-native-audio-toolkit.md | 37 +++++++++++++++++++++++++---- zh-cn/react-native-dropdownalert.md | 22 +++++++++++++++-- 2 files changed, 53 insertions(+), 6 deletions(-) diff --git a/zh-cn/react-native-audio-toolkit.md b/zh-cn/react-native-audio-toolkit.md index a2c2f9b0..337b4d5b 100644 --- a/zh-cn/react-native-audio-toolkit.md +++ b/zh-cn/react-native-audio-toolkit.md @@ -17,7 +17,13 @@ ## 安装与使用 -请到三方库的 Releases 发布地址查看配套的版本信息:[@react-native-oh-tpl/audio-toolkit Releases](https://github.com/react-native-oh-library/react-native-audio-toolkit/releases) 。对于未发布到npm的旧版本,请参考[安装指南](/zh-cn/tgz-usage.md)安装tgz包。 +请到三方库相应的 Releases 发布地址查看 Release 配套的版本信息: +| 三方库版本 | 发布信息 | 支持RN版本 | +| ---------- | ------------------------------------------------------------ | ---------- | +| 2.0.3 | [@react-native-oh-tpl/audio-toolkit Releases](https://github.com/react-native-oh-library/react-native-audio-toolkit/releases) | 0.72 | +| 2.0.4 | [@react-native-ohos/audio-toolkit Releases]() | 0.77 | + +对于未发布到npm的旧版本,请参考[安装指南](/zh-cn/tgz-usage.md)安装tgz包。 进入到工程目录并输入以下命令: @@ -26,13 +32,19 @@ #### **npm** ```bash +# 2.0.3 npm install @react-native-oh-tpl/audio-toolkit +# 2.0.4 +npm install @react-native-ohos/audio-toolkit ``` #### **yarn** ```bash +# 2.0.3 yarn add @react-native-oh-tpl/audio-toolkit +# 2.0.4 +yarn add @react-native-ohos/audio-toolkit ``` @@ -390,6 +402,8 @@ const styles = StyleSheet.create({ ## 使用 Codegen +> [!TIP] V2.0.4 for RN0.77 不需要执行 Codegen。 + 本库已经适配了 `Codegen` ,在使用前需要主动执行生成三方库桥接代码,详细请参考[ Codegen 使用文档](/zh-cn/codegen.md)。 ## Link @@ -421,13 +435,20 @@ const styles = StyleSheet.create({ > [!TIP] har 包位于三方库安装路径的 `harmony` 文件夹下。 打开 `entry/oh-package.json5`,添加以下依赖 - +- V2.0.3 ```json "dependencies": { "@rnoh/react-native-openharmony": "file:../react_native_openharmony", "@react-native-oh-tpl/audio-toolkit": "file:../../node_modules/@react-native-oh-tpl/audio-toolkit/harmony/audio_toolkit.har" } ``` +- V2.0.4 +```json +"dependencies": { + "@rnoh/react-native-openharmony": "file:../react_native_openharmony", + "@react-native-ohos/audio-toolkit": "file:../../node_modules/@react-native-ohos/audio-toolkit/harmony/audio_toolkit.har" + } +``` ### 3.在 ArkTs 侧引入 AudioModulesPackage @@ -435,8 +456,10 @@ const styles = StyleSheet.create({ ```diff ... - +// V2.0.3 + import { AudioModulesPackage } from "@react-native-oh-tpl/audio-toolkit/ts"; +// V2.0.4 ++ import { AudioModulesPackage } from "@react-native-ohos/audio-toolkit/ts"; export function createRNPackages(ctx: RNPackageContext): RNPackage[] { return [ @@ -478,7 +501,13 @@ ohpm install 要使用此库,需要使用正确的 React-Native 和 RNOH 版本。另外,还需要使用配套的 DevEco Studio 和 手机 ROM。 -请到三方库相应的 Releases 发布地址查看 Release 配套的版本信息:[@react-native-oh-tpl/audio-toolkit Releases](https://github.com/react-native-oh-library/react-native-audio-toolkit/releases/) +请到三方库相应的 Releases 发布地址查看 Release 配套的版本信息: +| 三方库版本 | 发布信息 | 支持RN版本 | +| ---------- | ------------------------------------------------------------ | ---------- | +| 2.0.3 | [@react-native-oh-tpl/audio-toolkit Releases](https://github.com/react-native-oh-library/react-native-audio-toolkit/releases) | 0.72 | +| 2.0.4 | [@react-native-ohos/audio-toolkit Releases]() | 0.77 | + +对于未发布到npm的旧版本,请参考[安装指南](/zh-cn/tgz-usage.md)安装tgz包。 ### 权限要求 diff --git a/zh-cn/react-native-dropdownalert.md b/zh-cn/react-native-dropdownalert.md index 5e187c23..0fac3d5a 100644 --- a/zh-cn/react-native-dropdownalert.md +++ b/zh-cn/react-native-dropdownalert.md @@ -16,7 +16,14 @@ ## 安装与使用 -请到三方库的 Releases 发布地址查看配套的版本信息:[@react-native-oh-tpl/react-native-dropdownalert Releases](https://github.com/react-native-oh-library/react-native-dropdownalert/releases) 。对于未发布到npm的旧版本,请参考[安装指南](/zh-cn/tgz-usage.md)安装tgz包。 +请到三方库的 Releases 发布地址查看配套的版本信息: + +| 三方库版本 | 发布信息 | 支持RN版本 | +| ---------- | ------------------------------------------------------------ | ---------- | +| 5.1.0 | [@react-native-oh-tpl/react-native-dropdownalert Releases](https://github.com/react-native-oh-library/react-native-dropdownalert/releases) | 0.72 | +| 5.1.1 | [@react-native-ohos/react-native-dropdownalert Releases]() | 0.77 | + +对于未发布到npm的旧版本,请参考[安装指南](/zh-cn/tgz-usage.md)安装tgz包。 进入到工程目录并输入以下命令: @@ -25,13 +32,19 @@ #### **npm** ```bash +# 5.1.0 npm install @react-native-oh-tpl/react-native-dropdownalert +# 5.1.1 +npm install @react-native-ohos/react-native-dropdownalert ``` #### **yarn** ```bash +# 5.1.0 yarn add @react-native-oh-tpl/react-native-dropdownalert +# 5.1.1 +yarn add @react-native-ohos/react-native-dropdownalert ``` @@ -247,7 +260,12 @@ export default App; 要使用此库,需要使用正确的 React-Native 和 RNOH 版本。另外,还需要使用配套的 DevEco Studio 和 手机 ROM。 -请到三方库相应的 Releases 发布地址查看 Release 配套的版本信息:[@react-native-oh-tpl/react-native-dropdownalert Releases](https://github.com/react-native-oh-library/react-native-dropdownalert/releases) +请到三方库的 Releases 发布地址查看配套的版本信息: + +| 三方库版本 | 发布信息 | 支持RN版本 | +| ---------- | ------------------------------------------------------------ | ---------- | +| 5.1.0 | [@react-native-oh-tpl/react-native-dropdownalert Releases](https://github.com/react-native-oh-library/react-native-dropdownalert/releases) | 0.72 | +| 5.1.1 | [@react-native-ohos/react-native-dropdownalert Releases]() | 0.77 | ## DropdownAlert -- Gitee