mirror of
https://github.com/discourse/discourse.git
synced 2025-02-22 04:07:27 +00:00
UX: Never show the back button if it's the last post
This commit is contained in:
parent
b42f28d4c3
commit
3d3ce56f52
@ -143,7 +143,7 @@ createWidget('timeline-scrollarea', {
|
||||
this.attach('timeline-padding', { height: after })
|
||||
];
|
||||
|
||||
if (position.lastRead) {
|
||||
if (position.lastRead && position.lastRead !== position.total) {
|
||||
const lastReadTop = Math.round(position.lastReadPercentage * SCROLLAREA_HEIGHT);
|
||||
if ((lastReadTop > (before + SCROLLER_HEIGHT)) && (lastReadTop < (SCROLLAREA_HEIGHT - SCROLLER_HEIGHT))) {
|
||||
result.push(this.attach('timeline-last-read', { top: lastReadTop, lastRead: position.lastRead }));
|
||||
|
Loading…
x
Reference in New Issue
Block a user