Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improvement of the triggering of detail page sections #1252

Open
dtrucs opened this issue Sep 17, 2024 · 0 comments
Open

Improvement of the triggering of detail page sections #1252

dtrucs opened this issue Sep 17, 2024 · 0 comments
Labels
enhancement New feature or request

Comments

@dtrucs
Copy link
Collaborator

dtrucs commented Sep 17, 2024

In detail pages, there are interactions between the sections being viewed (presentation, practical information, report, etc.) and other parts of the page, such as the map or the anchor menu.

To handle these interactions, the position and height of each section are calculated several times (when scrolling and resizing the window) to determine which section is currently being viewed and which is not. As a result of asynchronous changes in section heights (lazy image loading, widget taking a while to load, etc.), the calculation can fail and triggering accuracy is poorer.

The whole calculation process is a bit artisanal, and we should remedy this by using the dedicated intersection observer API (currently used by geotrek rando widget).

@dtrucs dtrucs added the enhancement New feature or request label Sep 17, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant