未验证 提交 4a7319e8 编写于 作者: O openharmony_ci 提交者: Gitee

!2930 Done! 2673:review api文档修改

Merge pull request !2930 from wusongqing/TR2673
......@@ -2,7 +2,9 @@
> ![icon-note.gif](public_sys-resources/icon-note.gif) **NOTE**
> The initial APIs of this module are supported since API version 3. Newly added APIs will be marked with a superscript to indicate their earliest API version.
>
> - The APIs of this module are no longer maintained since API version 7. You are advised to use [`@ohos.mediaquery`](js-apis-mediaquery.md) instead.
> - The initial APIs of this module are supported since API version 3. Newly added APIs will be marked with a superscript to indicate their earliest API version.
## Modules to Import
......@@ -23,14 +25,14 @@ Creates a **MediaQueryList** object based on the query condition.
**Parameters**
| Name| Type| Mandatory| Description|
| -------- | -------- | -------- | -------- |
| condition | string | Yes| Query condition.|
| Name | Type | Mandatory | Description |
| --------- | ------ | ---- | -------- |
| condition | string | Yes | Query condition.|
**Return value**
| Type| Description|
| -------- | -------- |
| Type | Description |
| -------------- | ---------------------------------------- |
| MediaQueryList | Attributes of the **MediaQueryList** object created. For details, see **MediaQueryList** attributes.|
**Example**
......@@ -49,9 +51,9 @@ Defines a media query event.
**System capability**: SystemCapability.ArkUI.ArkUI.Full
| Name| Type| Mandatory| Description|
| -------- | -------- | -------- | -------- |
| matches | boolean | Yes| Matching result.|
| Name | Type | Mandatory | Description |
| ------- | ------- | ---- | ----- |
| matches | boolean | Yes | Matching result.|
## MediaQueryList
......@@ -61,10 +63,10 @@ Defines a media query list.
**System capability**: SystemCapability.ArkUI.ArkUI.Full
| Name| Type| Mandatory| Description|
| -------- | -------- | -------- | -------- |
| media | string | No| Serialized media query condition. This parameter is read-only.|
| matches | boolean | Yes| Matching result.|
| Name | Type | Mandatory | Description |
| ------- | ------- | ---- | ----------------- |
| media | string | No | Serialized media query condition. This parameter is read-only.|
| matches | boolean | Yes | Matching result. |
### onchange
......@@ -76,9 +78,9 @@ Called when the **matches** value changes.
**Parameters**
| Name| Type| Mandatory| Description|
| -------- | -------- | -------- | -------- |
| matches | boolean | Yes| New **matches** value.|
| Name | Type | Mandatory | Description |
| ------- | ------- | ---- | -------------- |
| matches | boolean | Yes | New **matches** value.|
### MediaQueryList.addListener
......@@ -91,9 +93,9 @@ Adds a listener for this **MediaQueryList** object. The listener must be added b
**Parameters**
| Name| Type| Mandatory| Description|
| -------- | -------- | -------- | -------- |
| callback | (event: MediaQueryEvent) => void | Yes| Callback invoked when the matching condition changes.|
| Name | Type | Mandatory | Description |
| -------- | -------------------------------- | ---- | -------------- |
| callback | (event: MediaQueryEvent) => void | Yes | Callback invoked when the matching condition changes.|
**Example**
......@@ -112,9 +114,9 @@ Removes the listener for this **MediaQueryList** object.
**Parameters**
| Name| Type| Mandatory| Description|
| -------- | -------- | -------- | -------- |
| callback | (event: MediaQueryEvent) => void) | Yes| Callback invoked when the matching condition changes.|
| Name | Type | Mandatory | Description |
| -------- | --------------------------------- | ---- | -------------- |
| callback | (event: MediaQueryEvent) => void) | Yes | Callback invoked when the matching condition changes.|
**Example**
......
......@@ -2,7 +2,7 @@
> ![icon-note.gif](public_sys-resources/icon-note.gif) **NOTE**
>
> - The APIs of this module are no longer maintained since API version 8. You are advised to use ['@ohos.router'](js-apis-router.md) instead.
> - The APIs of this module are no longer maintained since API version 8. You are advised to use [`@ohos.router`](js-apis-router.md) instead.
>
>
> - The initial APIs of this module are supported since API version 3. Newly added APIs will be marked with a superscript to indicate their earliest API version.
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册