Skip to content

Commit

Permalink
docs: update ts 类型
Browse files Browse the repository at this point in the history
  • Loading branch information
yue1123 committed Oct 20, 2022
1 parent 4af5002 commit 5a9b095
Showing 1 changed file with 29 additions and 13 deletions.
42 changes: 29 additions & 13 deletions docs/zh/hooks/useTrackAnimation.md
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,7 @@
/>
<div class="state">
<span>动画状态: {{isRunning ? '已开始' : '未开始' }}</span>
<span>播放状态: {{isStopping ? '未播放' : '播放中' }}</span>
<span>播放状态: {{ !isRunning || isStopping ? '未播放' : '播放中' }}</span>
</div>
<button class="myButton no-m-b" type="button" @click="start">开始</button>
<button class="myButton no-m-b" type="button" @click="stop">暂停</button>
Expand Down Expand Up @@ -199,17 +199,33 @@ export declare type UseTrackAnimationOptions = {
* @returns { setPath, start, stop}
*/
export declare function useTrackAnimation(map: any, options: UseTrackAnimationOptions): {
/**
* 设置路径动画路径
*/
setPath: (path: PathPoint[]) => void;
/**
* 开始动画
*/
start: () => void;
/**
* 停止动画, 停止后再次开始,会重新播放
*/
stop: () => void;
/**
* 设置路径动画路径
*/
setPath: (path: PathPoint[]) => void;
/**
* 开始动画
*/
start: () => void;
/**
* 暂停动画
*/
stop: () => void;
/**
* 取消动画
*/
cancel: () => void;
/**
* 继续播放动画
*/
proceed: () => void;
/**
* 是否处于动画播放进度中
*/
isRunning: Ref<boolean>;
/**
* 是否暂停了播放
*/
isStopping: Ref<boolean>;
};
```

0 comments on commit 5a9b095

Please sign in to comment.