diff --git a/zh-cn/react-native-file-selector.md b/zh-cn/react-native-file-selector.md index fdabdd0095f4d7f3a0a0c6b805286fecaf0d6e9a..76d951203f9b3c11e0668582d8b3323a31c487e2 100644 --- a/zh-cn/react-native-file-selector.md +++ b/zh-cn/react-native-file-selector.md @@ -17,7 +17,13 @@ ## 安装与使用 -请到三方库的 Releases 发布地址查看配套的版本信息:[@react-native-oh-tpl/react-native-file-selector Releases](https://github.com/react-native-oh-library/react-native-file-selector/releases) 。对于未发布到npm的旧版本,请参考[安装指南](/zh-cn/tgz-usage.md)安装tgz包。 +请到三方库相应的 Releases 发布地址查看 Release 配套的版本信息: +| 三方库版本 | 发布信息 | 支持RN版本 | +| ---------- | ------------------------------------------------------------ | ---------- | +| 1.0.2 | [@react-native-oh-tpl/react-native-file-selector Releases](https://github.com/react-native-oh-library/react-native-file-selector/releases) | 0.72 | +| 1.0.3 | [@react-native-ohos/react-native-file-selector Releases]() | 0.77 | + +对于未发布到npm的旧版本,请参考[安装指南](/zh-cn/tgz-usage.md)安装tgz包。 进入到工程目录并输入以下命令: @@ -25,13 +31,19 @@ #### **npm** ```bash +# 1.0.2 npm install @react-native-oh-tpl/react-native-file-selector +# 1.0.3 +npm install @react-native-ohos/react-native-file-selector ``` #### **yarn** ```bash +# 1.0.2 yarn add @react-native-oh-tpl/react-native-file-selector +# 1.0.3 +yarn add @react-native-ohos/react-native-file-selector ``` @@ -55,6 +67,8 @@ export default App; ## 使用 Codegen +> [!TIP] V1.0.3 for RN0.77 不需要执行 Codegen。 + 本库已经适配了 `Codegen` ,在使用前需要主动执行生成三方库桥接代码,详细请参考[ Codegen 使用文档](/zh-cn/codegen.md)。 ## Link @@ -87,6 +101,7 @@ export default App; 打开 `entry/oh-package.json5`,添加以下依赖 +- V1.0.2 ```json "dependencies": { "@rnoh/react-native-openharmony" : "file:../react_native_openharmony", @@ -94,6 +109,14 @@ export default App; } ``` +- V1.0.3 +```json +"dependencies": { + "@rnoh/react-native-openharmony" : "file:../react_native_openharmony", + "@react-native-ohos/react-native-file-selector": "file:../../node_modules/@react-native-ohos/react-native-file-selector/harmony/file_selector.har" + } +``` + 点击右上角的 `sync` 按钮 或者在终端执行: diff --git a/zh-cn/react-native-touch-id.md b/zh-cn/react-native-touch-id.md index aaf10212386dbe532f4d7200fb86ea8e3b88b35a..bcb40ea00b58aa72936822bd0fdd1815a9049af6 100644 --- a/zh-cn/react-native-touch-id.md +++ b/zh-cn/react-native-touch-id.md @@ -16,8 +16,13 @@ ## 安装与使用 -请到三方库的 Releases 发布地址查看配套的版本信息:[@react-native-oh-tpl/react-native-touch-id Releases](https://github.com/react-native-oh-library/react-native-touch-id/releases) 。对于未发布到npm的旧版本,请参考[安装指南](/zh-cn/tgz-usage.md)安装tgz包。 +请到三方库相应的 Releases 发布地址查看 Release 配套的版本信息: +| 三方库版本 | 发布信息 | 支持RN版本 | +| ---------- | ------------------------------------------------------------ | ---------- | +| 4.4.1 | [@react-native-oh-tpl/react-native-touch-id Releases](https://github.com/react-native-oh-library/react-native-touch-id/releases) | 0.72 | +| 4.4.2 | [@react-native-ohos/react-native-touch-id Releases]() | 0.77 | +对于未发布到npm的旧版本,请参考[安装指南](/zh-cn/tgz-usage.md)安装tgz包。 进入到工程目录并输入以下命令: @@ -26,13 +31,19 @@ #### **npm** ```bash +# 4.4.1 npm install @react-native-oh-tpl/react-native-touch-id +# 4.4.2 +npm install @react-native-ohos/react-native-touch-id ``` #### **yarn** ```bash +# 4.4.1 yarn add @react-native-oh-tpl/react-native-touch-id +# 4.4.2 +yarn add @react-native-ohos/react-native-touch-id ``` @@ -78,6 +89,8 @@ export default App; ``` ## 使用 Codegen +> [!TIP] V4.4.2 for RN0.77 不需要执行 Codegen。 + 本库已经适配了 `Codegen` ,在使用前需要主动执行生成三方库桥接代码,详细请参考[ Codegen 使用文档](https://gitee.com/react-native-oh-library/usage-docs/blob/master/zh-cn/codegen.md)。 ## Link @@ -108,13 +121,19 @@ export default App; > [!TIP] har 包位于三方库安装路径的 `harmony` 文件夹下。 打开 `entry/oh-package.json5`,添加以下依赖 - +- V4.4.1 ```json "dependencies": { "@rnoh/react-native-openharmony": "file:../react_native_openharmony", "@react-native-oh-tpl/react-native-touch-id": "file:../../node_modules/@react-native-oh-tpl/react-native-touch-id/harmony/touch_id.har" } ``` +- V4.4.2 +```json +"dependencies": { + "@rnoh/react-native-openharmony": "file:../react_native_openharmony", + "@react-native-ohos/react-native-touch-id": "file:../../node_modules/@react-native-ohos/react-native-touch-id/harmony/touch_id.har" + } 点击右上角的 `sync` 按钮 @@ -136,7 +155,10 @@ ohpm install ```diff ... + // V4.4.1 + import { TouchIdPackage } from "@react-native-oh-tpl/react-native-touch-id/ts"; + // V4.4.2 ++ import { TouchIdPackage } from "@react-native-ohos/react-native-touch-id/ts"; export function createRNPackages(ctx: RNPackageContext): RNPackage[] { return [ @@ -166,8 +188,13 @@ ohpm install 要使用此库,需要使用正确的 React-Native 和 RNOH 版本。另外,还需要使用配套的 DevEco Studio 和 手机 ROM。 -请到三方库相应的 Releases 发布地址查看 Release 配套的版本信息:[@react-native-oh-tpl/react-native-touch-id Releases](https://github.com/react-native-oh-library/react-native-touch-id/releases) +请到三方库相应的 Releases 发布地址查看 Release 配套的版本信息: +| 三方库版本 | 发布信息 | 支持RN版本 | +| ---------- | ------------------------------------------------------------ | ---------- | +| 4.4.1 | [@react-native-oh-tpl/react-native-touch-id Releases](https://github.com/react-native-oh-library/react-native-touch-id/releases) | 0.72 | +| 4.4.2 | [@react-native-ohos/react-native-touch-id Releases]() | 0.77 | +对于未发布到npm的旧版本,请参考[安装指南](/zh-cn/tgz-usage.md)安装tgz包。 ### 权限要求 diff --git a/zh-cn/react-native-video-cache.md b/zh-cn/react-native-video-cache.md index e4302e333060fbd94f52250c7779ef9f09404668..32c7adfef0f39e97c676ffff39aead5ae0bac2fe 100644 --- a/zh-cn/react-native-video-cache.md +++ b/zh-cn/react-native-video-cache.md @@ -21,7 +21,13 @@ ## 安装与使用 -请到三方库的 Releases 发布地址查看配套的版本信息:[@react-native-oh-library/react-native-video-cache Releases](https://github.com/react-native-oh-library/react-native-video-cache/releases) 。对于未发布到npm的旧版本,请参考[安装指南](/zh-cn/tgz-usage.md)安装tgz包。 +请到三方库相应的 Releases 发布地址查看 Release 配套的版本信息: +| 三方库版本 | 发布信息 | 支持RN版本 | +| ---------- | ------------------------------------------------------------ | ---------- | +| 2.7.4 | [@react-native-oh-tpl/react-native-video-cache Releases](https://github.com/react-native-oh-library/react-native-video-cache/releases) | 0.72 | +| 2.7.5 | [@react-native-ohos/react-native-video-cache Releases]() | 0.77 | + +对于未发布到npm的旧版本,请参考[安装指南](/zh-cn/tgz-usage.md)安装tgz包。 进入到工程目录并输入以下命令: @@ -32,13 +38,19 @@ #### npm ```bash +# 2.7.4 npm install @react-native-oh-tpl/react-native-video-cache +# 2.7.5 +npm install @react-native-ohos/react-native-video-cache ``` #### yarn ```bash +# 2.7.4 yarn add @react-native-oh-tpl/react-native-video-cache +# 2.7.5 +yarn add @react-native-ohos/react-native-video-cache ``` @@ -120,12 +132,20 @@ const styles = StyleSheet.create({ 打开 `entry/oh-package.json5`,添加以下依赖 +- V2.7.4 ```json "dependencies": { "@rnoh/react-native-openharmony": "file:../react_native_openharmony", "@react-native-oh-tpl/rnoh-video-cache": "file:../../node_modules/@react-native-oh-tpl/react-native-video-cache/harmony/react_native_video_cache.har" } ``` +- V2.7.5 +```json +"dependencies": { + "@rnoh/react-native-openharmony": "file:../react_native_openharmony", + "@react-native-ohos/rnoh-video-cache": "file:../../node_modules/@react-native-ohos/react-native-video-cache/harmony/react_native_video_cache.har" + } +``` 点击右上角的 `sync` 按钮 @@ -142,6 +162,7 @@ ohpm install 打开 `entry/oh-package.json5`,添加以下依赖 +- V2.7.4 ```json "dependencies": { "@rnoh/react-native-openharmony": "file:../react_native_openharmony", @@ -149,6 +170,14 @@ ohpm install } ``` +- V2.7.5 +```json +"dependencies": { + "@rnoh/react-native-openharmony": "file:../react_native_openharmony", + "@react-native-ohos/rnoh-video-cache": "file:../../node_modules/@react-native-ohos/react-native-video-cache/harmony/react_native_video_cache" + } +``` + 打开终端,执行: ```bash @@ -191,7 +220,13 @@ ohpm install 要使用此库,需要使用正确的 React-Native 和 RNOH 版本。另外,还需要使用配套的 DevEco Studio 和 手机 ROM。 -请到三方库相应的 Releases 发布地址查看 Release 配套的版本信息:[@react-native-oh-library/react-native-video-cache Releases](https://github.com/react-native-oh-library/react-native-video-cache/releases)。 +请到三方库相应的 Releases 发布地址查看 Release 配套的版本信息: +| 三方库版本 | 发布信息 | 支持RN版本 | +| ---------- | ------------------------------------------------------------ | ---------- | +| 2.7.4 | [@react-native-oh-tpl/react-native-video-cache Releases](https://github.com/react-native-oh-library/react-native-video-cache/releases) | 0.72 | +| 2.7.5 | [@react-native-ohos/react-native-video-cache Releases]() | 0.77 | + +对于未发布到npm的旧版本,请参考[安装指南](/zh-cn/tgz-usage.md)安装tgz包。 本文档内容基于以下版本验证通过: 1. RNOH: 0.72.20-CAPI; SDK: HarmonyOS NEXT Developer Beta1(full sdk); IDE: DevEco Studio 5.0.3.200; ROM: 3.0.0.18;