Libraries defined in libraries-edit not loading in mobile & tablet preview

Created on 25 June 2024, 6 months ago

Problem/Motivation

When defining libraries in libraries-edit in the active theme, those libraries are loaded fine on the node edit page.

However, when using the mobile / tablet preview functionality, those libraries aren't added to the iframe.

Steps to reproduce

  • Define a library with custom css and/or js in the libraries-edit section of the .gutenberg.yml file in your active theme
  • Open node edit on a content type using the Gutenberg editor
  • Use the mobile / tablet preview functionality
  • Libraries aren't added to the preview iframe
🐛 Bug report
Status

Active

Version

3.0

Component

Code

Created by

🇧🇪Belgium rubendello

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

Comments & Activities

  • Issue created by @rubendello
  • This shows up in the console:

    wp-block-editor-content-css was added to the iframe incorrectly. Please use block.json or enqueue_block_assets to add styles to the iframe.

    wp-edit-blocks-css was added to the iframe incorrectly. Please use block.json or enqueue_block_assets to add styles to the iframe.

    wp-block-library-css was added to the iframe incorrectly. Please use block.json or enqueue_block_assets to add styles to the iframe.

    edit-node-editor-css was added to the iframe incorrectly. Please use block.json or enqueue_block_assets to add styles to the iframe.

    'Desktop view' works just fine.

Production build 0.71.5 2024