mirror of
https://github.com/flarum/core.git
synced 2025-08-05 16:07:34 +02:00
Add scrubber height change transition css, don't apply when dragging
This commit is contained in:
committed by
Franz Liedke
parent
9c63c54868
commit
9a357f5d19
@@ -50,8 +50,13 @@ export default class PostStreamScrubber extends Component {
|
||||
const handleHeight = Math.min(100 - beforeHeight, percentPerPost.visible * visible);
|
||||
const afterHeight = 100 - beforeHeight - handleHeight;
|
||||
|
||||
const classNames = ['PostStreamScrubber', 'Dropdown'];
|
||||
if (this.state.allVisible) classNames.push('disabled');
|
||||
if (this.dragging) classNames.push('dragging');
|
||||
if (this.props.className) classNames.push(this.props.className);
|
||||
|
||||
return (
|
||||
<div className={'PostStreamScrubber Dropdown ' + (this.state.allVisible() ? 'disabled ' : '') + (this.props.className || '')}>
|
||||
<div className={classNames.join(' ')}>
|
||||
<button className="Button Dropdown-toggle" data-toggle="dropdown">
|
||||
{viewing} {icon('fas fa-sort')}
|
||||
</button>
|
||||
|
@@ -21,6 +21,14 @@
|
||||
}
|
||||
.Scrubber-before, .Scrubber-after {
|
||||
border-left: 1px solid @control-bg;
|
||||
transition: height 0.15s ease-out;
|
||||
}
|
||||
.Scrubber-before, .Scrubber-after {
|
||||
border-left: 1px solid @control-bg;
|
||||
transition: height 0.15s ease-out;
|
||||
}
|
||||
.dragging .Scrubber-before, .dragging .Scrubber-after {
|
||||
transition: none;
|
||||
}
|
||||
.Scrubber-unread {
|
||||
position: absolute;
|
||||
|
Reference in New Issue
Block a user