Giter Site home page Giter Site logo

Comments (10)

benjamminf avatar benjamminf commented on August 19, 2024

Hey @jgl221 thanks for the report. I was able to reproduce the issue and found out why this was happening. Similar situation to #21 so it's actually a problem with Craft's built-in Matrix field too (although you wouldn't usually run into this problem with Matrix as you don't need to filter by level).

Simple enough solution so I've gone ahead and fixed it already. I'll be releasing a new version today at some point with the fix 👍

from craft-neo.

jgl221 avatar jgl221 commented on August 19, 2024

That's great, thank you for the quick response and fix! My clients will be very happy :)

from craft-neo.

benjamminf avatar benjamminf commented on August 19, 2024

No problem! I haven't made the release yet as I've fixed some issues relating to localisation that I want to test thoroughly before it's available. If you can't wait any longer, grab the neo/models/Neo_CriteriaModel.php file from the dev branch and replace the existing one on your site. This will fix your issue.

from craft-neo.

jgl221 avatar jgl221 commented on August 19, 2024

I grabbed the updated file from the dev branch and it's mostly working but seems to have one other caveat. Top-level blocks that I modify are updating on the Draft, but changes to child blocks aren't updating. Live Preview is again still working though. I imagine we're just missing a loop to go through modified child blocks on Draft mode? Or maybe it's something more complex?

from craft-neo.

benjamminf avatar benjamminf commented on August 19, 2024

Unfortunately it's a lot more complex than that. Does it work correctly with live preview with child blocks?

If it does, I will find it a little strange that live preview would work but not drafts, since it's the same code running in both situations. Otherwise I probably missed something somewhere...

from craft-neo.

jgl221 avatar jgl221 commented on August 19, 2024

Perhaps I oversimplified it just a tad :)

But yes, Live Preview is working fine with both top-level and child block modifications. I thought maybe it had to do with caching or locale, but even with caching and locales turned off, I'm still seeing the same behavior where the Live Preview is showing the modifications on child blocks on drafts, but the draft token link when saved doesn't display the changes.

from craft-neo.

benjamminf avatar benjamminf commented on August 19, 2024

Haha no it's a fair assumption, but it turns out how Live Preview (and Drafts) work in Craft is fundamentally flawed and it's taken quite a large amount of effort to get Neo to work around this problem. Clearly it's harder than I thought, as I'm still receiving issue reports relating to it.

Thanks for the clarification. I'll see what I can do, but I won't lie it's a little confusing. I'll keep this thread updated.

from craft-neo.

jgl221 avatar jgl221 commented on August 19, 2024

Thanks @benjamminf I appreciate your help! I don't doubt that it's very complicated, especially so if the fundamental way they work in Craft is wonky already.

from craft-neo.

benjamminf avatar benjamminf commented on August 19, 2024

Good news, I figured it out :) Turns out I just missed some checks when adding in support for draft preview links. New version of Neo to be released over the weekend (probably).

from craft-neo.

jgl221 avatar jgl221 commented on August 19, 2024

You're the tops! Thanks so much for the help.

from craft-neo.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.