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

Site editor theme export: Include local media in theme assets #41798

Open
carolinan opened this issue Jun 18, 2022 · 2 comments
Open

Site editor theme export: Include local media in theme assets #41798

carolinan opened this issue Jun 18, 2022 · 2 comments
Labels
Developer Experience Ideas about improving block and theme developer experience [Feature] Site Editor Related to the overarching Site Editor (formerly "full site editing") [Feature] Themes Questions or issues with incorporating or styling blocks in a theme. [Type] Enhancement A suggestion for improvement.

Comments

@carolinan
Copy link
Contributor

carolinan commented Jun 18, 2022

What problem does this address?

When creating a block theme using the Site Editor, chances are that you want to add media like images and video.
If you choose media from the local media library, these files are not included when you export the theme.
The path to the media still points to the media library.

Some blocks allow using remote media, but remote media is not always an option.
-For example, if you want to share your theme in the WordPress.org theme directory, remote files are not allowed.
-We also can not use s.w.org as some sort of public image CDN for our themes (this is where some images for the pattern directory are hosted).

This leaves a manual step to include media in the theme and update the paths. I believe we need to solve this so that we can use the export as part of no-code theme creation.

What is your proposed solution?

Find a way to identify the media, save it in the theme folder, and update the paths.

@carolinan carolinan added the [Feature] Themes Questions or issues with incorporating or styling blocks in a theme. label Jun 18, 2022
@LukaszJaro
Copy link

I exported patterns/reusable blocks from local to dev/stg and paths ended up being broken to the media, they were still pointing to my local install. I didn't notice this until someone else viewed it on their device and noticed images were not loading.

@skorasaurus
Copy link
Member

reference about not being about to provide local paths to media: #20966

@carolinan carolinan added [Feature] Site Editor Related to the overarching Site Editor (formerly "full site editing") Developer Experience Ideas about improving block and theme developer experience labels Jul 24, 2023
@jordesign jordesign added the [Type] Enhancement A suggestion for improvement. label Sep 8, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Developer Experience Ideas about improving block and theme developer experience [Feature] Site Editor Related to the overarching Site Editor (formerly "full site editing") [Feature] Themes Questions or issues with incorporating or styling blocks in a theme. [Type] Enhancement A suggestion for improvement.
Projects
None yet
Development

No branches or pull requests

4 participants