diff --git a/en/react-native-device-info.md b/en/react-native-device-info.md index a776519472431748f34a91fe30b166a28102e953..654973eb3247b89a2804d7bc21478532ec395de8 100644 --- a/en/react-native-device-info.md +++ b/en/react-native-device-info.md @@ -1,43 +1,33 @@ -> Template version: v0.2.2 +> Template version: v0.4.0

react-native-device-info

-

- - Supported platforms - - - License - -

- -> [!TIP] [GitHub address](https://github.com/react-native-oh-library/react-native-device-info) - -## Installation and Usage +This project is based on [react-native-device-info](https://github.com/react-native-oh-library/react-native-device-info) 。 -Please refer to the Releases page of the third-party library for the corresponding version information +This third-party library has been migrated to Gitcode and is now available for direct download from npm, the new package name is:`@react-native-ohos/react-native-device-info` The version correspondence details are as follows: +| Name | Version | Release Information | Supported RN Version | Supported Autolink | Compile API Version | Community Baseline Version | npm Address | +| ------------ | ------------ | ------------------------------ | ------------- | ------------- |------------------------ | ------------- | ------------- | +| @react-native-ohos/react-native-device-info | ~ 14.1.2 | [Gitcode Releases](https://gitcode.com/openharmony-sig/rntpc_react-native-device-info/releases) | 0.82.* | No | API12+ | 14.1.1 | [Npm Address](https://www.npmjs.com/package/@react-native-ohos/react-native-device-info) | +| @react-native-ohos/react-native-device-info | ~ 14.0.5 | [Gitcode Releases](https://gitcode.com/openharmony-sig/rntpc_react-native-device-info/releases) | 0.77.* | No | API12+ | 14.0.4 | [Npm Address](https://www.npmjs.com/package/@react-native-ohos/react-native-device-info) | +| @react-native-ohos/react-native-device-info | ~ 11.1.1 | [Gitcode Releases](https://gitcode.com/openharmony-sig/rntpc_react-native-device-info/releases) | 0.72.* | Yes | API12+ | 11.1.0 | [Npm Address](https://www.npmjs.com/package/@react-native-ohos/react-native-device-info) | +| @react-native-oh-tpl/react-native-device-info | <= 11.1.0-0.0.8@deprecated | [Github Releases](https://github.com/react-native-oh-library/react-native-device-info/releases) | 0.72.* | No | API12+ | 11.1.0 | [Npm Address](https://www.npmjs.com/package/@react-native-oh-tpl/react-native-device-info) | -| Third-party Library Version | Release Information | Supported RN Version | -|-------| ------------------------------------------------------------ | ---------- | -| <= 11.1.0-0.0.8@deprecated | [@react-native-oh-tpl/react-native-device-info Releases(deprecated)](https://github.com/react-native-oh-library/react-native-device-info/releases) | 0.72 | -| 11.1.1 | [@react-native-ohos/react-native-device-info Releases](https://gitcode.com/openharmony-sig/rntpc_react-native-device-info/releases) | 0.72 | -| 14.0.5 | [@react-native-ohos/react-native-device-info Releases](https://gitcode.com/openharmony-sig/rntpc_react-native-device-info/releases) | 0.77 | -For older versions that are not published to npm, please refer to the [installation guide](/en/tgz-usage-en.md) to install the tgz package. +## 1. Installation and Usage Go to the project directory and execute the following instruction: -#### **npm** +#### npm ```bash npm install @react-native-ohos/react-native-device-info ``` -#### **yarn** +#### yarn ```bash yarn add @react-native-ohos/react-native-device-info @@ -49,7 +39,7 @@ The following code shows the basic use scenario of the repository: > [!WARNING] The name of the imported repository remains unchanged. -```js +```tsx import { SafeAreaView, @@ -185,42 +175,43 @@ export default App; } ``` -## Use Codegen +## 2. Manual Link +| | Supported Autolink | Supported RN Version | +|--------------------------------------|--------------|--------| +| ~14.1.2 | No | 0.82 | +| ~14.0.5 | No | 0.77 | +| ~11.1.1 | Yes | 0.72 | +| <= 11.1.0-0.0.8@deprecated | No | 0.72 | -This library has been adapted for `Codegen`. Before using it, you need to proactively generate the bridge code for the third-party library. For details, please refer to the [Codegen Usage Documentation](/en/codegen.md). +Projects using AutoLink need to be configured according to this document, AutoLink framework guide.:https://gitcode.com/openharmony-sig/ohos_react_native/blob/master/docs/zh-cn/Autolinking.md -## Link +If the version you are using supports Autolink and the project has integrated Autolink, you can skip the ManualLink configuration. -| | Is supported autolink | Supported RN Version | -|--------------------------------------|-----------------------|----------------------| -| ~14.0.5 | No | 0.77 | -| ~11.1.1 | Yes | 0.72 | -| <= 11.1.0-0.0.8@deprecated | No | 0.72 | - -Using AutoLink need to be configured according to this document, Autolink Framework Guide Documentation: https://gitcode.com/openharmony-sig/ohos_react_native/blob/master/docs/zh-cn/Autolinking.md - -If the version you use supports Autolink and the project has been connected to Autolink, skip the ManualLink configuration.
- ManualLink: this step is a guide to manually configure native dependencies. + ManualLink: This step provides guidance for manually configuring native dependencies. -First, use DevEco Studio to open the HarmonyOS project `harmony` in the project directory. +Open the `harmony` directory of the HarmonyOS project in DevEco Studio. -### 1. Adding the overrides Field to oh-package.json5 File in the Root Directory of the Project +### 2.1. Overrides RN SDK +To ensure the project relies on the same version of the RN SDK, you need to add an `overrides` field in the project's root `oh-package.json5` file, specifying the RN SDK version to be used. The replacement version can be a specific version number, a semver range, or a locally available HAR package or source directory. + +For more information about the purpose of this field, please refer to the [official documentation](https://developer.huawei.com/consumer/en/doc/harmonyos-guides-V5/ide-oh-package-json5-V5#en-us_topic_0000001792256137_overrides). ```json { - ... "overrides": { - "@rnoh/react-native-openharmony" : "./react_native_openharmony" + "@rnoh/react-native-openharmony": "file:../react_native_openharmony" } } ``` -### 2. Introducing Native Code +### 2.2. Introducing Native Code Currently, two methods are available: +- Use the HAR file. +- Directly link to the source code。 Method 1 (recommended): Use the HAR file. @@ -231,8 +222,8 @@ Open `entry/oh-package.json5` file and add the following dependencies: ```json "dependencies": { "@rnoh/react-native-openharmony": "file:../react_native_openharmony", - "@react-native-ohos/react-native-device-info": "file:../../node_modules/@react-native-ohos/react-native-device-info/harmony/device_info.har" - } +"@react-native-ohos/react-native-device-info": "file:../../node_modules/@react-native-ohos/react-native-device-info/harmony/device_info.har" +} ``` Click the `sync` button in the upper right corner. @@ -248,29 +239,22 @@ Method 2: Directly link to the source code. > [!TIP] For details, see [Directly Linking Source Code](/en/link-source-code.md). -### 3.Configuring CMakeLists and Introducing RNDeviceInfoPackage +### 2.3. Configuring CMakeLists and Introducing RNDeviceInfoPackage > If you are using version <= 11.1.0-0.0.8, please skip this chapter. -Open `entry/src/main/cpp/CMakeLists.txt` and add the following code +Open `entry/src/main/cpp/CMakeLists.txt` and add the following code: ```diff -project(rnapp) -cmake_minimum_required(VERSION 3.4.1) -set(CMAKE_CXX_STANDARD 17) -set(RNOH_CPP_DIR "${CMAKE_CURRENT_SOURCE_DIR}/../../../../oh_modules/@rnoh/react-native-openharmony/src/main/cpp") + set(REACT_NATIVE_DEVICE_INFO_CPP_DIR "${CMAKE_CURRENT_SOURCE_DIR}/../../../oh_modules/@react-native-ohos/react-native-device-info/src/main/cpp") -set(WITH_HITRACE_SYSTRACE 1) -add_compile_definitions(WITH_HITRACE_SYSTRACE) -add_subdirectory("${RNOH_CPP_DIR}" ./rn) +# RNOH_BEGIN: manual_package_linking_1 + add_subdirectory("${REACT_NATIVE_DEVICE_INFO_CPP_DIR}" ./device_info) +# RNOH_END: manual_package_linking_1 -add_library(rnoh_app SHARED - "./PackageProvider.cpp" - "${RNOH_CPP_DIR}/RNOHAppNapiBridge.cpp" -) +# RNOH_BEGIN: manual_package_linking_2 + target_link_libraries(rnoh_app PUBLIC device_info) +# RNOH_END: manual_package_linking_2 ``` Open `entry/src/main/cpp/PackageProvider.cpp` and add the following code: @@ -285,13 +269,12 @@ using namespace rnoh; std::vector> PackageProvider::getPackages(Package::Context ctx) { return { std::make_shared(ctx), - std::make_shared(ctx), + std::make_shared(ctx), }; } ``` -### 4. Introducing RNDeviceInfoPackage to ArkTS +### 2.4. Introducing RNDeviceInfoPackage to ArkTS Open the `entry/src/main/ets/RNPackagesFactory.ts` file and add the following code: @@ -301,14 +284,13 @@ Open the `entry/src/main/ets/RNPackagesFactory.ts` file and add the following co export function createRNPackages(ctx: RNPackageContext): RNPackage[] { return [ - new SamplePackage(ctx), + new RNDeviceInfoPackage(ctx) ]; } ```
-## Running +### 2.5. Running Click the `sync` button in the upper right corner. @@ -321,21 +303,17 @@ ohpm install Then build and run the code. -## Constraints +## 3. Constraints -### Compatibility +### 3.1. Compatibility -To use this repository, you need to use the correct React-Native and RNOH versions. In addition, you need to use DevEco Studio and the ROM on your phone. - -Verified in the following versions. +This document is verified based on the following versions: 1. RNOH: 0.72.96; SDK: HarmonyOS 6.0.0 Release SDK; IDE: DevEco Studio 6.0.0.858; ROM: 6.0.0.112; 2. RNOH: 0.72.33; SDK: HarmonyOS NEXT B1; IDE: DevEco Studio: 5.0.3.900; ROM: Next.0.0.71; 3. RNOH: 0.77.18; SDK: HarmonyOS 6.0.0 Release SDK; IDE: DevEco Studio 6.0.0.858; ROM: 6.0.0.112; -### Permission Requirements - -#### Add permissions in the module.json5 file under the entry directory. +### 3.2. Permission Requirements Open `entry/src/main/module.json5`, add the following permission: @@ -361,7 +339,15 @@ Open `entry/src/main/module.json5`, add the following permission: ] ``` -## API +### 3.3. API requirements + +> [!TIP] All versions of the current third-party libraries have implemented version isolation, supporting compilation in `API12+` projects and execution on `API12+` ROMs. + +> [!TIP] The following features depend on specific API versions. Compiling the project with an API version lower than specified or running the ROM with an API version lower than specified may result in limited functionality. + +1. Version 14.0.5-rc.4 introduced [getFontScale](https://developer.huawei.com/consumer/cn/doc/harmonyos-references/js-apis-app-ability-configuration#configuration), achieves the current system font scaling ratio retrieval functionality. This API requires compilation in a project that supports `API18+` and must run on a ROM that supports `API18+` to take effect. + +## 4. API > [!TIP] The **Platform** column indicates the platform where the properties are supported in the original third-party library. @@ -456,7 +442,7 @@ Open `entry/src/main/module.json5`, add the following permission: | getStartupTime14.0.4+ | Get the current application process startup time in milliseconds. | Promise\ | Yes | iOS/Android/visionOS | yes | -## Known Issues +## 5. Known Issues - [ ] Does not support getDeviceId() in harmony [issue#8](https://github.com/react-native-oh-library/react-native-device-info/issues/8) - [ ] Does not support getDeviceToken() in harmony [issue#9](https://github.com/react-native-oh-library/react-native-device-info/issues/9) @@ -478,13 +464,13 @@ Open `entry/src/main/module.json5`, add the following permission: - [ ] Does not support hasNotch() in harmony [issue#25](https://github.com/react-native-oh-library/react-native-device-info/issues/25) - [ ] Does not support hasDynamicIsland() in harmony [issue#26](https://github.com/react-native-oh-library/react-native-device-info/issues/26) - [ ] Does not support hasSystemFeature() in harmony [issue#27](https://github.com/react-native-oh-library/react-native-device-info/issues/27) -- [ ] Does not support isEmulator() in harmony [issue#28](https://github.com/react-native-oh-library/react-native-device-info/issues/28) +- [ ] Does not support isEmulator() in harmony [issue#28](https://github.com/react-native-oh-library/react-native-device-info/issues/28) - [ ] Does not support isDisplayZoomed() in harmony [issue#29](https://github.com/react-native-oh-library/react-native-device-info/issues/29) - [ ] Does not support getBrightness() in harmony [issue#30](https://github.com/react-native-oh-library/react-native-device-info/issues/30) - [ ] Does not support isAirplaneMode() in harmony [issue#69](https://github.com/react-native-oh-library/react-native-device-info/issues/69) -## Others +## 6. Others -## License +## 7. License This project is licensed under [The MIT License (MIT)](https://github.com/react-native-device-info/react-native-device-info/blob/master/LICENSE). diff --git a/zh-cn/react-native-device-info.md b/zh-cn/react-native-device-info.md index 7aacd081ea9e4ec61991ce307a94772fcb0c5eb7..11239c685b6583050e66178b717e85693c19e4aa 100644 --- a/zh-cn/react-native-device-info.md +++ b/zh-cn/react-native-device-info.md @@ -1,42 +1,33 @@ -> 模板版本:v0.2.2 +> 模板版本:v0.4.0

react-native-device-info

-

- - Supported platforms - - - License - -

- -> [!TIP] [Github 地址](https://github.com/react-native-oh-library/react-native-device-info) -## 安装与使用 +本项目基于 [react-native-device-info](https://github.com/react-native-oh-library/react-native-device-info) 开发。 -请到三方库的 Releases 发布地址查看配套的版本信息: +该第三方库的仓库已迁移至 Gitcode,且支持直接从 npm 下载,新的包名为:`@react-native-ohos/react-native-device-info` 版本所属关系如下: +| 三方库名称 | 三方库版本 | 发布信息 | 支持RN版本 | Autolink | 编译API版本 | 社区基线版本 | npm地址 | +| ------------ | ------------ | ------------------------------ | ------------- | ------------- |------------------------ | ------------- | ------------- | +| @react-native-ohos/react-native-device-info | ~ 14.1.2 | [Gitcode Releases](https://gitcode.com/openharmony-sig/rntpc_react-native-device-info/releases) | 0.82.* | 否 | API12+ | 14.1.1 | [Npm Address](https://www.npmjs.com/package/@react-native-ohos/react-native-device-info) | +| @react-native-ohos/react-native-device-info | ~ 14.0.5 | [Gitcode Releases](https://gitcode.com/openharmony-sig/rntpc_react-native-device-info/releases) | 0.77.* | 否 | API12+ | 14.0.4 | [Npm Address](https://www.npmjs.com/package/@react-native-ohos/react-native-device-info) | +| @react-native-ohos/react-native-device-info | ~ 11.1.1 | [Gitcode Releases](https://gitcode.com/openharmony-sig/rntpc_react-native-device-info/releases) | 0.72.* | 是 | API12+ | 11.1.0 | [Npm Address](https://www.npmjs.com/package/@react-native-ohos/react-native-device-info) | +| @react-native-oh-tpl/react-native-device-info | <= 11.1.0-0.0.8@deprecated | [Github Releases](https://github.com/react-native-oh-library/react-native-device-info/releases) | 0.72.* | 否 | API12+ | 11.1.0 | [Npm Address](https://www.npmjs.com/package/@react-native-oh-tpl/react-native-device-info) | -| 三方库版本 | 发布信息 | 支持RN版本 | -|-------| ------------------------------------------------------------ | ---------- | -| <= 11.1.0-0.0.8@deprecated | [@react-native-oh-tpl/react-native-device-info Releases(deprecated)](https://github.com/react-native-oh-library/react-native-device-info/releases) | 0.72 | -| 11.1.1 | [@react-native-ohos/react-native-device-info Releases](https://gitcode.com/openharmony-sig/rntpc_react-native-device-info/releases) | 0.72 | -| 14.0.5 | [@react-native-ohos/react-native-device-info Releases](https://gitcode.com/openharmony-sig/rntpc_react-native-device-info/releases) | 0.77 | - -对于未发布到npm的旧版本,请参考[安装指南](/zh-cn/tgz-usage.md)安装tgz包。 + +## 1. 安装与使用 进入到工程目录并输入以下命令: -#### **npm** +#### npm ```bash npm install @react-native-ohos/react-native-device-info ``` -#### **yarn** +#### yarn ```bash yarn add @react-native-ohos/react-native-device-info @@ -48,7 +39,8 @@ yarn add @react-native-ohos/react-native-device-info > [!WARNING] 使用时 import 的库名不变。 -```js +```tsx + import { SafeAreaView, ScrollView, @@ -183,18 +175,14 @@ export default App; } ``` -## 使用 Codegen +## 2. Link - -本库已经适配了 `Codegen` ,在使用前需要主动执行生成三方库桥接代码,详细请参考[ Codegen 使用文档](/zh-cn/codegen.md)。 - -## Link - -| | 是否支持autolink | RN框架版本 | -|--------------------------------------|------------------|-----------| -| ~14.0.5 | No | 0.77 | -| ~11.1.1 | Yes | 0.72 | -| <= 11.1.0-0.0.8@deprecated | No | 0.72 | +| | 是否支持autolink | RN框架版本 | +|----------------------------|--------------|--------| +| ~14.1.2 | No | 0.82 | +| ~14.0.5 | No | 0.77 | +| ~11.1.1 | Yes | 0.72 | +| <= 11.1.0-0.0.8@deprecated | No | 0.72 | 使用AutoLink的工程需要根据该文档配置,Autolink框架指导文档:https://gitcode.com/openharmony-sig/ohos_react_native/blob/master/docs/zh-cn/Autolinking.md @@ -204,23 +192,26 @@ export default App; 首先需要使用 DevEco Studio 打开项目里的 HarmonyOS 工程 `harmony`。 -### 1.在工程根目录的 `oh-package.json5` 添加 overrides 字段 +### 2.1. Overrides RN SDK + +为了让工程依赖同一个版本的 RN SDK,需要在工程根目录的 `oh-package.json5` 添加 overrides 字段,指向工程需要使用的 RN SDK 版本。替换的版本既可以是一个具体的版本号,也可以是一个模糊版本,还可以是本地存在的 HAR 包或源码目录。 + +关于该字段的作用请阅读[官方说明](https://developer.huawei.com/consumer/cn/doc/harmonyos-guides-V5/ide-oh-package-json5-V5#zh-cn_topic_0000001792256137_overrides) ```json { - ... "overrides": { - "@rnoh/react-native-openharmony" : "./react_native_openharmony" + "@rnoh/react-native-openharmony": "file:../react_native_openharmony" } } ``` -### 2.引入原生端代码 +### 2.2. 引入原生端代码 目前有两种方法: -1. 通过 har 包引入(在 IDE 完善相关功能后该方法会被遗弃,目前首选此方法); -2. 直接链接源码。 +- 通过 har 包引入; +- 直接链接源码。 方法一:通过 har 包引入(推荐) @@ -232,12 +223,12 @@ export default App; "dependencies": { "@rnoh/react-native-openharmony": "file:../react_native_openharmony", "@react-native-ohos/react-native-device-info": "file:../../node_modules/@react-native-ohos/react-native-device-info/harmony/device_info.har" - } +} ``` 点击右上角的 `sync` 按钮 -或者在终端执行: +或者在命令行终端执行: ```bash cd entry @@ -248,29 +239,22 @@ ohpm install > [!TIP] 如需使用直接链接源码,请参考[直接链接源码说明](/zh-cn/link-source-code.md) -### 3.配置 CMakeLists 和引入 RNDeviceInfoPackage +### 2.3. 配置 CMakeLists 和引入 RNDeviceInfoPackage -> 若使用的是 <= 11.1.0-0.0.8 版本,请跳过本章。 +> 若使用的是 <= 11.1.0-0.0.8 版本,请跳过本章。 打开 `entry/src/main/cpp/CMakeLists.txt`,添加: ```diff -project(rnapp) -cmake_minimum_required(VERSION 3.4.1) -set(CMAKE_CXX_STANDARD 17) -set(RNOH_CPP_DIR "${CMAKE_CURRENT_SOURCE_DIR}/../../../../oh_modules/@rnoh/react-native-openharmony/src/main/cpp") + set(REACT_NATIVE_DEVICE_INFO_CPP_DIR "${CMAKE_CURRENT_SOURCE_DIR}/../../../oh_modules/@react-native-ohos/react-native-device-info/src/main/cpp") -set(WITH_HITRACE_SYSTRACE 1) -add_compile_definitions(WITH_HITRACE_SYSTRACE) -add_subdirectory("${RNOH_CPP_DIR}" ./rn) +# RNOH_BEGIN: manual_package_linking_1 + add_subdirectory("${REACT_NATIVE_DEVICE_INFO_CPP_DIR}" ./device_info) +# RNOH_END: manual_package_linking_1 -add_library(rnoh_app SHARED - "./PackageProvider.cpp" - "${RNOH_CPP_DIR}/RNOHAppNapiBridge.cpp" -) +# RNOH_BEGIN: manual_package_linking_2 + target_link_libraries(rnoh_app PUBLIC device_info) +# RNOH_END: manual_package_linking_2 ``` 打开 `entry/src/main/cpp/PackageProvider.cpp`,添加: @@ -285,13 +269,12 @@ using namespace rnoh; std::vector> PackageProvider::getPackages(Package::Context ctx) { return { std::make_shared(ctx), - std::make_shared(ctx), + std::make_shared(ctx), }; } ``` -### 4.在 ArkTs 侧引入 RNDeviceInfoPackage +### 2.4. 在 ArkTs 侧引入 RNDeviceInfoPackage 打开 `entry/src/main/ets/RNPackagesFactory.ts`,添加: @@ -301,18 +284,17 @@ std::vector> PackageProvider::getPackages(Package::Cont export function createRNPackages(ctx: RNPackageContext): RNPackage[] { return [ - new SamplePackage(ctx), + new RNDeviceInfoPackage(ctx) ]; } ``` -## 运行 +### 2.5. 运行 点击右上角的 `sync` 按钮 -或者在终端执行: +或者在命令行终端执行: ```bash cd entry @@ -321,21 +303,17 @@ ohpm install 然后编译、运行即可。 -## 约束与限制 +## 3. 约束与限制 -### 兼容性 +### 3.1. 兼容性 -要使用此库,需要使用正确的 React-Native 和 RNOH 版本。另外,还需要使用配套的 DevEco Studio 和 手机 ROM。 - -在以下版本验证通过: +本文档内容基于以下版本验证通过: 1. RNOH: 0.72.96; SDK: HarmonyOS 6.0.0 Release SDK; IDE: DevEco Studio 6.0.0.858; ROM: 6.0.0.112; 2. RNOH: 0.72.33; SDK: HarmonyOS NEXT B1; IDE: DevEco Studio: 5.0.3.900; ROM: Next.0.0.71; 3. RNOH: 0.77.18; SDK: HarmonyOS 6.0.0 Release SDK; IDE: DevEco Studio 6.0.0.858; ROM: 6.0.0.112; -### 权限要求 - -#### 在 entry 目录下的module.json5中添加权限 +### 3.2. 权限要求 打开 `entry/src/main/module.json5`,添加: @@ -361,7 +339,14 @@ ohpm install ] ``` -## API +### 3.3. 编译运行API要求 + +> [!TIP] 当前三方库所有版本均已实现版本隔离,支持在 `API12+` 工程编译,及 `API12+` ROM运行。 + +> [!TIP] 以下功能依赖特定版本的API,使用 `低于指定API版本的工程编译` 或 `低于指定API版本的ROM运行` 均可能导致部分功能受限。 +1. 14.0.5-rc.4 版本引入[getFontScale](https://developer.huawei.com/consumer/cn/doc/harmonyos-references/js-apis-app-ability-configuration#configuration),实现了获取当前系统的字体缩放比例功能,此API需要在支持`API18+`的工程编译,并在支持`API18+`的ROM上运行,方可生效。 + +## 4. API > [!TIP] "Platform"列表示该属性在原三方库上支持的平台。 @@ -457,7 +442,8 @@ ohpm install | getStartupTime14.0.4+ | 获取当前应用程序进程启动的时间,单位为毫秒。 | Promise\ | Yes | iOS/Android/visionOS | yes | -## 遗留问题 + +## 5. 遗留问题 - [ ] getDeviceId()接口harmony暂不支持[issue#8](https://github.com/react-native-oh-library/react-native-device-info/issues/8) - [ ] getDeviceToken()接口harmony暂不支持[issue#9](https://github.com/react-native-oh-library/react-native-device-info/issues/9) @@ -475,17 +461,17 @@ ohpm install - [ ] getUniqueId()接口harmony暂不支持 [issue#21](https://github.com/react-native-oh-library/react-native-device-info/issues/21) - [ ] syncUniqueId()接口harmony暂不支持 [issue#22](https://github.com/react-native-oh-library/react-native-device-info/issues/22) - [ ] getUserAgent()接口harmony暂不支持 [issue#23](https://github.com/react-native-oh-library/react-native-device-info/issues/23) -- [ ] getUserAgentSync()接口harmony暂不支持 [issue#24](https://github.com/react-native-oh-library/react-native-device-info/issues/24) +- [ ] getUserAgentSync()接口harmony暂不支持 [issue#24](https://github.com/react-native-oh-library/react-native-device-info/issues/24) - [ ] hasNotch()接口harmony暂不支持 [issue#25](https://github.com/react-native-oh-library/react-native-device-info/issues/25) - [ ] hasDynamicIsland()接口harmony暂不支持 [issue#26](https://github.com/react-native-oh-library/react-native-device-info/issues/26) - [ ] hasSystemFeature()接口harmony暂不支持 [issue#27](https://github.com/react-native-oh-library/react-native-device-info/issues/27) -- [ ] isEmulator()接口harmony暂不支持 [issue#28](https://github.com/react-native-oh-library/react-native-device-info/issues/28) +- [ ] isEmulator()接口harmony暂不支持 [issue#28](https://github.com/react-native-oh-library/react-native-device-info/issues/28) - [ ] isDisplayZoomed()接口harmony暂不支持 [issue#29](https://github.com/react-native-oh-library/react-native-device-info/issues/29) - [ ] getBrightness()接口harmony暂不支持 [issue#30](https://github.com/react-native-oh-library/react-native-device-info/issues/30) - [ ] isAirplaneMode()接口harmony暂不支持 [issue#69](https://github.com/react-native-oh-library/react-native-device-info/issues/69) -## 其他 +## 6. 其他 -## 开源协议 +## 7. 开源协议 本项目基于 [The MIT License (MIT)](https://github.com/react-native-device-info/react-native-device-info/blob/master/LICENSE) ,请自由地享受和参与开源。