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

Theme created with create block theme in WP 6.2 don't work as expected in WP 6.3 #439

Open
TVScoundrel opened this issue Aug 9, 2023 · 5 comments

Comments

@TVScoundrel
Copy link

My theme is completely ignoring the templates. The templates look fine in the editor, but when visiting the web pages, everything is jumbled.

Here is my template
front page template

Here is what the page looks like
home page visited

@pbking
Copy link
Contributor

pbking commented Aug 9, 2023

Can you supply the exported theme?

@TVScoundrel
Copy link
Author

For sure, here you go.

It was based on a complete blank.

officenest.zip

@pbking
Copy link
Contributor

pbking commented Aug 10, 2023

So far the biggest issues with the theme attached are the following:

Navigation block (in header template-part) has a ref attribute. These need to be removed when exporting and is covered by this Gutenberg issue. I can see a point to this being functionality in CBT until that ships, but regardless this is why the navigation doesn't work as expected out-of-the-box.

Secondly the 'home-page' pattern is referencing a template-part (header). This is the biggest issue with exporting themes right now and the hardest to handle. This PR to Gutenberg may address it, but in the meantime you just can't have patterns that reference template-parts. Your theme works OK just by moving the header template-part block from the front-page pattern to the front-page template.

Lastly the image referenced in the front-page pattern is this: /assets/images/OfficeNest-workspace-scaled.jpg but that resource is not included in the theme.

I'm not sure which of those I would consider a fault of Create Block Theme; it's hard to tell.

@TVScoundrel
Copy link
Author

TVScoundrel commented Aug 10, 2023

Thanks for checking @pbking, I should maybe point out that this was on a server with CBT installed, created from a blank template and edited in the editor. I did no direct code changes, but I did use the now hidden page wp-admin/customize.php to add custom CSS.

So I was still in the middle of developing the theme when my provider decided to push WP6.3 out, after which everything stopped working as expected.

So I didn't actually do any export and import from my theme, only after you asked me to provide the theme, but the chance is that because the server is now running 6.3, it is not exporting everything as we would expect.

I have asked my provider to downgrade my version back to 6.2 after which everything started working again. I am not sure how to fix this, but I think I will just recreate my theme from scratch using CBT directly on WP6.3 because it looks like eventually, my provider will insist on updating.

@pbking
Copy link
Contributor

pbking commented Aug 10, 2023

Ok, that is also helpful information; thank you.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants