mirror of
https://github.com/flarum/core.git
synced 2025-08-06 08:27:42 +02:00
Move data from vnode
to vnode.state
`vnode.state` is persisted, `vnode` might not be
This commit is contained in:
committed by
Franz Liedke
parent
bdc64f98a5
commit
b954e79ec8
@@ -41,13 +41,13 @@ export default class PostStreamScrubber extends Component {
|
|||||||
height: unreadPercent * 100 + '%',
|
height: unreadPercent * 100 + '%',
|
||||||
};
|
};
|
||||||
|
|
||||||
if (vnode.oldStyle) {
|
if (vnode.state.oldStyle) {
|
||||||
$element.stop(true).css(vnode.oldStyle).animate(newStyle);
|
$element.stop(true).css(vnode.state.oldStyle).animate(newStyle);
|
||||||
} else {
|
} else {
|
||||||
$element.css(newStyle);
|
$element.css(newStyle);
|
||||||
}
|
}
|
||||||
|
|
||||||
vnode.oldStyle = newStyle;
|
vnode.state.oldStyle = newStyle;
|
||||||
}
|
}
|
||||||
const classNames = ['PostStreamScrubber', 'Dropdown'];
|
const classNames = ['PostStreamScrubber', 'Dropdown'];
|
||||||
if (this.attrs.className) classNames.push(this.attrs.className);
|
if (this.attrs.className) classNames.push(this.attrs.className);
|
||||||
|
Reference in New Issue
Block a user