Use IntersectionObserver to update map on entering viewport to fix visibility issue

Created on 20 February 2023, over 1 year ago
Updated 25 February 2023, over 1 year ago

Problem/Motivation

The leaflet version of the issue and branch in geofield_map 🐛 Geofield Map Widget visibility issue inside field group, with Leaflet library Fixed .

Which should fix issues such as:

Steps to reproduce

Add geofield to entity. Configure to use for widget: leaflet (default). Install field group and ptu the widget into a tab, accordion etc. where the map is initially not visible. Create/Edit an entity and click through to see the map.

Proposed resolution

Use the IntersectionObserver discussed in 🐛 Geofield Map Widget visibility issue inside field group, with Leaflet library Fixed to trigger a leaflet invalidateSize.

Remaining tasks

User interface changes

It works in field groups :)

API changes

None

Data model changes

None

📌 Task
Status

Fixed

Version

10.0

Component

Code

Created by

🇳🇱Netherlands ekes

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Production build 0.69.0 2024