Skip to content

Commit

Permalink
fix: 修复timeline 不能自动播放的问题
Browse files Browse the repository at this point in the history
  • Loading branch information
zengyue committed Oct 26, 2021
1 parent d16fc32 commit 3e30137
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions packages/f2-next/src/base/diff.ts
Original file line number Diff line number Diff line change
Expand Up @@ -144,8 +144,6 @@ function diffElement(nextElement: JSX.Element, lastElement: JSX.Element) {
destroyElement(lastElement);
return null;
}
// react 生成的 element 是 not extensible 的,这里新建一个新对象,并把需要的内容pick 出来
nextElement = pickElement(nextElement);

// 新建
if (nextElement && !lastElement) {
Expand Down Expand Up @@ -244,6 +242,8 @@ function isContainer(children: JSX.Element) {
}

function renderChildren(parent: Component, nextChildren, lastChildren) {
// react 生成的 element 是 not extensible 的,这里新建一个新对象,并把需要的内容pick 出来
nextChildren = pickElement(nextChildren);
parent.children = nextChildren;

if (isContainer(nextChildren)) {
Expand Down

0 comments on commit 3e30137

Please sign in to comment.