-
Notifications
You must be signed in to change notification settings - Fork 2.3k
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
Project index turbofy #16246
Project index turbofy #16246
Conversation
9824cd2
to
5e538dd
Compare
ce8e3a0
to
3d64498
Compare
Handing over the baton to you, @aaron-contreras. This PR is mostly done in its core functionality. I have wrapped the page header and the table in turbo wrappers that we can replace from the backend. The very advantage that we have is that all modifying actions on a With the help of turbo_power we can even do the I have also wrapped the The next step would be to change the filter component to also issue the request via turbo stream when a filter is changed, get rid of the apply button and basically allow setting filters like we do on the work package page. That should then be used to implement the new always visible text filter. There's also some strange behavior in the tests right now. When manually trying in a browser, the toast flash messages do show up. In the tests it does not work, that's why the tests on toasts are still commented out |
5b67ddb
to
4d72459
Compare
This makes sure that the DOM can remain agnostic of this behavior of auto-submitting and we can rely on the Stimulus controller taking care of most of this logic which in the end, pretty much relies on that end of the spectrum.
4d72459
to
30d7c96
Compare
8d0b7a7
to
93a6e3e
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Overall looks good, just a few questions @aaron-contreras 🌴
@@ -169,7 +174,8 @@ | |||
|
|||
# Can save the project list | |||
projects_index_page.save_query | |||
projects_index_page.expect_toast(message: "The modified list has been saved") | |||
# TODO: Toast is currently not rendered in turbo actions | |||
# projects_index_page.expect_toast(message: "The modified list has been saved") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do you have any idea why the toast is sent as a stream properly but isn't on the test suite e473b9c? I believe Klaus mentioned there was some funny behavior with the toast in the specs. There should be a PR Oliver and Mir are working on for a better way to deal with this that SHOULD resolve this weird behavior in specs. @dombesz
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's been a while ago, but I think there was something problematic because the way how the toast javascript was triggered was that it only worked on the page load and it did not properly work with turbo. But I'm not 100% sure where this was
This reverts commit e473b9c.
As of #16246 the project list is "turbofied" by default
As of #16246 the project list is "turbofied" by default
Make the project index view be able to render different components with turbo streams.
This is already functional. The Page header, menu, filter list, flashes and project list are already dynamically updated via Turbo Streams.
Closes https://community.openproject.org/work_packages/56557