From d93110a40516171f485ad2998c3a189e7a6e156f Mon Sep 17 00:00:00 2001 From: "ester.zhou" Date: Mon, 25 Jul 2022 18:41:09 +0800 Subject: [PATCH] update ts-universal-attributes-opacity.md Signed-off-by: ester.zhou --- .../arkui-ts/ts-universal-attributes-opacity.md | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/en/application-dev/reference/arkui-ts/ts-universal-attributes-opacity.md b/en/application-dev/reference/arkui-ts/ts-universal-attributes-opacity.md index 03c5ded623..8f9d11414c 100644 --- a/en/application-dev/reference/arkui-ts/ts-universal-attributes-opacity.md +++ b/en/application-dev/reference/arkui-ts/ts-universal-attributes-opacity.md @@ -1,11 +1,12 @@ # Opacity -> ![icon-note.gif](public_sys-resources/icon-note.gif) **NOTE** +> **NOTE** +> > This attribute is supported since API version 7. Updates will be marked with a superscript to indicate their earliest API version. -The attributes described in this topic are used to set the opacity of a component. +You can set the opacity of a component. ## Required Permissions @@ -16,15 +17,16 @@ None ## Attributes - | Name | Type | Default Value | Description | +| Name | Type | Default Value | Description | | -------- | -------- | -------- | -------- | -| opacity | number | 1 | Opacity of a component. The value ranges from **0** to **1**. The value **1** means opaque, and **0** means completely transparent. | +| opacity | number \| [Resource](../../ui/ts-types.md) | 1 | Opacity of a component. The value ranges from **0** to **1**. The value **1** means opaque, and **0** means completely transparent. | ## Example - -``` + +```ts +// xxx.ets @Entry @Component struct OpacityExample { -- GitLab