Skip to content

Site Editor Compatibility: Map block #19482

@andrewserong

Description

@andrewserong

In the new site editor in Gutenberg (/wp-admin/admin.php?page=gutenberg-edit-site), there are some issues with the Map block in the editor. The Map block itself appears to be able to be initialised within the site editor canvas, likely as a result of the editor canvas being rendered within an iframe. It looks like Mapbox expects to be given a string to match against a DOM node, or be given a DOM node.

Is there a way for us to get the Mapbox initialisation to play nicely with an iframe?

Steps to reproduce the issue

  1. With the Gutenberg plugin active (>=10.4.0-rc1), activate a block-ready theme (like tt1-blocks)
  2. In the site editor, insert a Map block into the Footer template part
  3. Observe that the map block throws an error as in the screenshot below
  4. Save the template part
  5. Observe that the map does render on the front end of the site

What I expected

The map to render and be usable within the editor

What happened instead

The map isn't rendered, and throws an error
image

Metadata

Metadata

Assignees

Labels

BugWhen a feature is broken and / or not performing as intended[Block] Map[Focus] BlocksIssues related to the block editor, aka Gutenberg, and its extensions developed in Jetpack[Focus] FSEIssues related to the site editor / Full Site Editing / FSE feature in Gutenberg

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions