laravelista / comments

Native comments for your Laravel application.
MIT License
744 stars 142 forks source link

Issue ''jumping'' to comments with pagination #114

Closed ScuffedNewt closed 3 years ago

ScuffedNewt commented 4 years ago

When using links to ''jump'' a user to a comment ( e.g https://sitename.com/user/{username}#comment-1 ) if the comment is on, for example, the second paginated page ( https://sitename.com/user/{username}?page=2 ) the ''jump'' link will not correctly display the referenced comment, and will instead stay on the first page of pagination.

Not sure if this is a bug, or just a limitation of the code being used, but any help with this would be very much appreciated!

We tried to figure a way to calculate what page a comment was likely to land on by dividing by our pagination number, but we realised pretty fast that it more than likely wouldn't work because it would not work with our seperate 'permalink' view.

ScuffedNewt commented 3 years ago

Fixed this with a permalinking view!