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

Implementation/57028 removal of a project leaves some angular components as not clickable #16495

Conversation

akabiru
Copy link
Member

@akabiru akabiru commented Aug 21, 2024

https://community.openproject.org/work_packages/57028

This reverts commit f3a0db2.

Update the controller to respond with partial turbo streams instead of a full page redirect with turbo enabled. This caused DOM load issues with angular components, as Turbo would not break out of it's navigation frame- to remount the angular web components. The solution here is also used in other similar pages such as project attributes.

Kapture.2024-08-21.at.14.10.11.mp4

This reverts commit f3a0db2.

Update the controller to respond with partial turbo streams instead of a full page redirect with turbo enabled. This caused DOM load issues with angular components, as Turbo would not break out of it's navigation frame- to remount the angular web components. The solution here is also used in other similar pages such as project attributes.
@akabiru akabiru marked this pull request as ready for review August 21, 2024 11:13
disabled: true,
data: {
"disable-when-checked-target": "effect",
"close-dialog-id": id
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@judithroth One odd thing is I had to specify the close-dialog-id - in other cases, the dialog closes automatically on submit 🤷🏾

layout.with_row(mb: 3) do
render(Primer::Beta::Heading.new(tag: :h1, text_align: :center)) do
render(Primer::Beta::Octicon.new(icon: :alert, color: :danger, size: :medium))
component_wrapper do
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is just for semantics and convention, but since async dialogs replace stream content via JS, it's technically not necessary- which is why it worked before without it.

Copy link
Contributor

@judithroth judithroth left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just replacing parts of the page is of course another solution to the problem 👍
:shipit:

@akabiru akabiru merged commit eb5def9 into dev Aug 21, 2024
9 checks passed
@akabiru akabiru deleted the implementation/57028-removal-of-a-project-leaves-some-angular-components-as-not-clickable branch August 21, 2024 11:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

2 participants