Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update my.getSystemInfo.md #2103

Open
wants to merge 2 commits into
base: main
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 22 additions & 0 deletions mini/api/基础API/设备/系统信息/my.getSystemInfo.md
Original file line number Diff line number Diff line change
Expand Up @@ -75,10 +75,32 @@ success 回调函数会携带一个 Object 类型的对象,其属性如下:
| screen | Object | 屏幕宽度和高度。结构为: { width: Number, height: Number } 单位:px。 |
| screenWidth | Number | 屏幕宽度。单位:px。此属性在 Android 上取值有误,**建议使用 screen.width 替代。** |
| screenHeight | Number | 屏幕高度。单位:px。此属性在 Android 上取值有误,**建议使用 screen.height 替代。** |
| safeArea | Object | 在竖屏正方向下的安全区域。单位:px。|
| safeArea | Object | 在竖屏正方向下的安全区域插入位置。单位:px。|
| brand | String | 手机品牌。 |
| fontSizeSetting | Number | 用户设置字体大小。单位:px |
| app | String | 当前运行的客户端。若当前为支付宝,则有效值为 "alipay"。不同的客户端,对应的有效值如下:<ul><li>alipay:支付宝。</li><li>UC:UC 浏览器。</li><li>QUARK:夸克浏览器。</li><li>AK:阿里健康。</li><li>amap:高德。</li><li>YK:优酷。</li><li>DINGTALK:钉钉。</li></ul> |

#### safeArea 返回值说明

| **手机型号** | **类型** | **说明** |
| ----------------- | -------------- | ------------------------- |
| top | number | 安全区域左上角纵坐标 |
| bottom | number | 安全区域右下角纵坐标 |
| left | number | 安全区域左上角横坐标 |
| right | number | 安全区域右下角横坐标 |
| height | number | 安全区域的高度 |
| width | number | 安全区域的宽度 |

#### safeAreaInsets 返回值说明
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

没有 safeAreaInsets 这个出参

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

image
1669096563549
在IOS和安卓的开发者工具中都获取到了safeAreaInsets的值,IOS真机调试中也获取到了,因为目前手上没有安卓机所以看不到安卓真机调试的数据,但这个接口应该是有safeAreaInsets的出参的


| **手机型号** | **类型** | **说明** |
| ----------------- | -------------- | ------------------------- |
| top | number | 安全区顶部插入位置 |
| bottom | number | 安全区底部插入位置 |
| left | number | 安全区域左侧插入位置 |
| right | number | 安全区域右侧插入位置 |

#### model 参数

对于 iPhone,model 参数将返回 iPhone 内部代码(Internal Name)。iPhone 手机型号与对应的 model 返回值如下表所示:
Expand Down