未验证 提交 146cb040 编写于 作者: O openharmony_ci 提交者: Gitee

!6262 【轻量级 PR】:【文档体验官】更新animator描述

Merge pull request !6262 from wusongqing/N/A
# 动画
> ![icon-note.gif](public_sys-resources/icon-note.gif) **说明:**
> **说明:**
>
> 本模块首批接口从API version 6开始支持。后续版本的新增接口,采用上角标单独标记接口的起始版本。
......@@ -22,7 +23,7 @@ createAnimator(options: AnimatorOptions): AnimatorResult
**参数:**
| 参数名 | 类型 | 必填 | 说明 |
| -------- | -------- | -------- | -------- |
| options | [AnimatorOptions](#animatoroptions) | 是 | 定义动画选项,详细请参考AnimatorOptions。|
| options | [AnimatorOptions](#animatoroptions) | 是 | 定义动画选项。|
**返回值:**
| 类型 | 说明 |
......@@ -169,7 +170,7 @@ animator.reverse();
onframe: (progress: number) => void
回调时触发
接收到帧时回调
**系统能力:** SystemCapability.ArkUI.ArkUI.Full
......@@ -187,7 +188,7 @@ animator.onframe();
onfinish: () => void
动画完成。
动画完成时回调
**系统能力:** SystemCapability.ArkUI.ArkUI.Full
......@@ -200,7 +201,7 @@ animator.onfinish();
oncancel: () => void
动画被取消。
动画被取消时回调
**系统能力:** SystemCapability.ArkUI.ArkUI.Full
......@@ -213,6 +214,8 @@ animator.oncancel();
onrepeat: () => void
动画重复时回调。
**系统能力:** SystemCapability.ArkUI.ArkUI.Full
**示例:**
......@@ -220,8 +223,6 @@ onrepeat: () => void
animator.onrepeat();
```
动画将重复。
## AnimatorOptions
定义动画选项。
......@@ -236,5 +237,5 @@ animator.onrepeat();
| fill | "none" \| "forwards" \| "backwards" \| "both" | 是 | 动画执行后是否恢复到初始状态,默认值为"none"。动画执行后,动画结束时的状态(在最后一个关键帧中定义)将保留。 |
| direction | "normal" \| "reverse" \| "alternate" \| "alternate-reverse" | 是 | 动画播放模式,默认值"normal"。|
| iterations | number | 是 | 动画播放次数,默认值1。设置为0时不播放,设置为-1时无限次播放。 |
| begin | number | 是 | 动画插值起点,不设置时默认为0。 |
| end | number | 是 | 动画插值终点,不设置时默认为1。 |
| begin | number | 是 | 动画插值起点,默认为0。 |
| end | number | 是 | 动画插值终点,默认为1。 |
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册