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

[Admin] Open edit and new forms in dialog with turbo frame #6046

Open
wants to merge 12 commits into
base: main
Choose a base branch
from

Conversation

tvdeyen
Copy link
Member

@tvdeyen tvdeyen commented Dec 20, 2024

Depends on #6048

Summary

Opens new and edit forms of Admin resources in dialogs with Turbo Frames.
Removing the need of rendering the index table again on the form components.

Also handles the layout toggle for all turbo frame requests.

Includes the ground work from #6045

  • Shipping Categories
  • Adjustment reasons
  • Return reasons
  • Store credit reasons
  • Refund reasons
  • Tax categories
  • User roles

Closes #5944

Checklist

Check out our PR guidelines for more details.

The following are mandatory for all PRs:

The following are not always needed:

  • 📖 I have updated the README to account for my changes.
  • 📑 I have documented new code with YARD.
  • 🛣️ I have opened a PR to update the guides.
  • ✅ I have added automated tests to cover my changes.
  • 📸 I have attached screenshots to demo visual changes.

@tvdeyen tvdeyen force-pushed the open-modal-content-remotely branch 2 times, most recently from 22f5345 to 5e2c4da Compare December 20, 2024 10:57
3.21.0 introduced a bug with testing view components.
@tvdeyen tvdeyen force-pushed the open-modal-content-remotely branch from 5e2c4da to 909607d Compare December 20, 2024 20:02
@tvdeyen tvdeyen changed the title [Admin] Open Shipping Categories edit and new forms in dialog with turbo frame [Admin] Open edit and new forms in dialog with turbo frame Dec 20, 2024
@tvdeyen tvdeyen marked this pull request as ready for review December 20, 2024 20:05
@tvdeyen tvdeyen requested a review from a team as a code owner December 20, 2024 20:05
@tvdeyen tvdeyen force-pushed the open-modal-content-remotely branch from 909607d to 184c645 Compare December 20, 2024 20:10
If a table has no rowUrl defined we currently redirect to
root path. Which is not preferable. We should do nothing instead.
We do not want to render the whole layout if the request
is a turbo frame request. We just want to render the
component's html.
@tvdeyen tvdeyen force-pushed the open-modal-content-remotely branch from 354c7c2 to a1e9278 Compare December 20, 2024 20:28
Copy link

codecov bot commented Dec 20, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 89.59%. Comparing base (9234436) to head (a1e9278).

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #6046      +/-   ##
==========================================
+ Coverage   87.82%   89.59%   +1.76%     
==========================================
  Files         477      791     +314     
  Lines       11670    18254    +6584     
==========================================
+ Hits        10249    16354    +6105     
- Misses       1421     1900     +479     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@tvdeyen tvdeyen force-pushed the open-modal-content-remotely branch from a1e9278 to 162d93c Compare December 20, 2024 20:54
@tvdeyen tvdeyen force-pushed the open-modal-content-remotely branch from 162d93c to ca8ae78 Compare December 20, 2024 21:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Admin] Table component rows do not contain links
2 participants