-
Notifications
You must be signed in to change notification settings - Fork 115
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
xilem_masonry: Add filter ("All", "Active", "Completed") to todomvc example #265
base: main
Are you sure you want to change the base?
xilem_masonry: Add filter ("All", "Active", "Completed") to todomvc example #265
Conversation
f4f11bb
to
1767ca5
Compare
Nicely done, but as you point out, this PR makes these other bugs very visible. I'd rather not merge it until they are fixed, since this is our showcase. ^^ |
Sure, I also think this should only be merged, when it doesn't produce obvious bugs at this point :). But I think it's probably good for debugging these bugs. |
1767ca5
to
c95fcd5
Compare
(Now this weird issue can be debugged, since #264 is merged) |
I ran in (I think) the same issue that you are describing, put some reproduction steps here: https://xi.zulipchat.com/#narrow/stream/354396-xilem/topic/TodoMVC.20example/near/437314215 |
c95fcd5
to
c0c1b73
Compare
Since #278 is merged, I've tested this again, it works now as expected |
For what it's worth, it also moves around in the examples on todomvc.com. |
Yes checkboxes are not ideal indeed, these should be exchanged with the right widgets, when they're implemented. I'm not sure how much we're striving towards the original TodoMVC. |
I've been looking through our PR backlog, and I'd be interested in merging this, if everything works correctly after a rebase. I'm fine having checkboxes masquerade as combo buttons for now, as long as we track it in an issue. We can add a big ugly "TODO - replace with combo buttons" comment to the example. |
c0c1b73
to
bc556fb
Compare
I've rebased it (+ added comment), and well it revealed yet another new bug^^ (this example seems to be a quite good test as well) To reproduce: |
Hmm, so the behaviour we see is that the checkbox "thinks" it is clicked, but without sending an action. That's very strange |
bc556fb
to
927dbb7
Compare
I rebased this again, to check whether that issue resolved itself - not the case. So the issue is related to two-way dataflow and non-keyed widgets/viewsequences. I.e. masonry modifies the checkbox value while it shouldn't do it (at least in this case). I think this is an example, that two-way dataflow can be a pitfall for declarative frameworks on top of masonry. I think it would be great to find a general clean solution for this issue (something like opt-in control of the state in masonry, as in this case). I've pushed a "fix"/workaround, which should make this work as expected. |
This seems like a very "brute force" solution to the two-way dataflow problem, buuuuut nobody has a better idea, so we may as well ship it. |
This adds the filters of TodoMVC via checkboxes currently (as we currently don't have better widgets for that...).
It also revealed (at least) 2 bugs, one being fixed by #264 and another I (or someone else) needs to investigate (difficult to describe just add a few todos, check them, and click all the filters, it should be easy to reproduce).