-
Notifications
You must be signed in to change notification settings - Fork 63
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
Redactor fields cannot be initialized when lazy loading new blocks inside Solspace Calendar #790
Comments
I just looked a similar issue (craftcms/cms#13752), thinking it may be related to a change in Steps to reproduce:
The issue is that Neo is not capturing any of the JS resources that are registered while rendering a newly-created block. ( You can fix by adding the following to the return array in 'bodyHtml' => $this->getView()->getBodyHtml(), Then in your JS code, pass (Note that Craft 4.5.6 did actually introduce a bug that could impact this. Fixed now in 4.5.6.1, so make sure you’re running that.) |
Oh, and it looks like this was introduced in Neo 3.9.0. |
Thanks @brandonkelly. I had originally tried to fix this earlier today by adding the Craft view's |
I can confirm the issue was introduced in 3.9.0, if i downgrade to 3.8.6 the redactor fields work again (craft 4.5.5) |
Well anyway, for whatever reason |
@ttempleton Now that you have JS buffering only really makes sense for the way Matrix blocks are added (and presumably Neo before 3.9.0?), where we loop through each of the block types and capture what a brand new block’s HTML and JS should look like up front, but without actually executing the JS until a block is added. |
Ah okay, that makes sense, thanks 👍 |
Bug Description
I have a Neo field containing a Redactor field. After updating to 3.9.2 which includes the new lazy loading behavior, the Redactor field shows up fine when editing an entry.
The same field is also being used inside a Solspace Calendar Event entry. With lazy loading enabled, the Redactor JS field is missing crucial JS (and CSS) assets:
The affected site is using
solspace/craft-calendar:4.0.9
Please let me know if this bug report is better directed at Solspace.
Steps to reproduce
enableLazyLoadingNewBlocks
totrue
enableLazyLoadingNewBlocks
tofalse
– Redactor field gets initialized correctlyExpected behaviour
No response
Neo version
3.9.2
Craft CMS version
4.5.6
What is the affected Neo field's propagation method?
all
Does this issue involve templating, and if so, is eager-loading used?
This is not a templating issue
The text was updated successfully, but these errors were encountered: