mirror of
https://github.com/discourse/discourse.git
synced 2025-09-07 12:02:53 +08:00
UX: Never show the back button if it's the last post
This commit is contained in:
parent
b42f28d4c3
commit
3d3ce56f52
1 changed files with 1 additions and 1 deletions
|
@ -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…
Add table
Add a link
Reference in a new issue