Merge pull request #5746 from matrix-org/travis/fix-rr-rel
[Release] Change read receipt drift to be non-fractional
This commit is contained in:
commit
c160a66a94
1 changed files with 2 additions and 2 deletions
|
@ -156,14 +156,14 @@ export default class ReadReceiptMarker extends React.PureComponent {
|
||||||
// then shift to the rightmost column,
|
// then shift to the rightmost column,
|
||||||
// and then it will drop down to its resting position
|
// and then it will drop down to its resting position
|
||||||
//
|
//
|
||||||
// XXX: We use a fractional left value to trick velocity-animate into actually animating.
|
// XXX: We use a small left value to trick velocity-animate into actually animating.
|
||||||
// This is a very annoying bug where if it thinks there's no change to `left` then it'll
|
// This is a very annoying bug where if it thinks there's no change to `left` then it'll
|
||||||
// skip applying it, thus making our read receipt at +14px instead of +0px like it
|
// skip applying it, thus making our read receipt at +14px instead of +0px like it
|
||||||
// should be. This does cause a tiny amount of drift for read receipts, however with a
|
// should be. This does cause a tiny amount of drift for read receipts, however with a
|
||||||
// value so small it's not perceived by a user.
|
// value so small it's not perceived by a user.
|
||||||
// Note: Any smaller values (or trying to interchange units) might cause read receipts to
|
// Note: Any smaller values (or trying to interchange units) might cause read receipts to
|
||||||
// fail to fall down or cause gaps.
|
// fail to fall down or cause gaps.
|
||||||
startStyles.push({ top: startTopOffset+'px', left: '0.001px' });
|
startStyles.push({ top: startTopOffset+'px', left: '1px' });
|
||||||
enterTransitionOpts.push({
|
enterTransitionOpts.push({
|
||||||
duration: bounce ? Math.min(Math.log(Math.abs(startTopOffset)) * 200, 3000) : 300,
|
duration: bounce ? Math.min(Math.log(Math.abs(startTopOffset)) * 200, 3000) : 300,
|
||||||
easing: bounce ? 'easeOutBounce' : 'easeOutCubic',
|
easing: bounce ? 'easeOutBounce' : 'easeOutCubic',
|
||||||
|
|
Loading…
Reference in a new issue