Closed joseabernardes closed 3 months ago
The latest updates on your projects. Learn more about Vercel for Git ↗︎
Azure Static Web Apps: Your stage site is ready! Visit it here: https://icy-water-049ec4003-778.westeurope.3.azurestaticapps.net
Azure Static Web Apps: Your stage site is ready! Visit it here: https://icy-water-049ec4003-778.westeurope.3.azurestaticapps.net
Summary
To solve the problem, I changed the strategy that defines the current page. Previously, we defined the current page as the first visible page and, when the user scrolled down to the end of the file, we defined the current page as the last one (actually, that was the bug, because we were defining the second to last page and not the last one). The new strategy defines the current page as the first most visible page, so that when we have two visible pages, the current one is the most visible, which is the standard behaviour in other file viewers, such as Chrome. The only edge case I've found is when we have small pages (height) and we can have two full pages visible at the end of the viewer, it will consider the current one as the first one. From what I've found, this is also what Chrome is considering, so I wouldn't consider it a problem.
If you have any question reach out!
Review Checklist
General
For new or updated components
https://swirl-storybook.flip-app.dev/?path=/docs/contributions-merge-publish--page