Skip to content

Conversation

@AllanKoder
Copy link
Owner

No description provided.

Copilot AI review requested due to automatic review settings December 30, 2025 21:58
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR implements error flash message handling and makes UI improvements to the resource edits feature. The changes enable error messages to be displayed as toast notifications, fix error handling to use flash messages consistently, and improve the back button UI. However, critical debug code was accidentally left in the controller that will break the create functionality.

Key changes:

  • Added error flash message support across the frontend (ToastHandler, Inertia middleware) and backend (controller error handling)
  • Enhanced back button with text label and improved spacing
  • Simplified slug generation to use only edit_title (removed id from source)

Reviewed changes

Copilot reviewed 6 out of 6 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
app/Http/Controllers/ResourceEditsController.php Changed error handling from withErrors to flash messages; contains debug code that must be removed
app/Http/Middleware/HandleInertiaRequests.php Added error flash data to Inertia shared props
resources/js/Components/ToastHandler.vue Added error toast handling for flash.error messages
resources/js/Pages/ResourceEdits/Create.vue Added text label to back button for better UX
resources/js/Components/Navigation/BackButton.vue Changed margin from top-only to vertical for better spacing
app/Models/ResourceEdits.php Simplified slug source to use only edit_title instead of edit_title and id

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
@AllanKoder AllanKoder merged commit 24612c2 into master Dec 30, 2025
3 checks passed
@AllanKoder AllanKoder deleted the resource-edits-and-notifs branch December 30, 2025 22:13
AllanKoder added a commit that referenced this pull request Dec 30, 2025
* changes

* Apply automatic changes

* Update app/Http/Controllers/ResourceEditsController.php

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
AllanKoder added a commit that referenced this pull request Dec 30, 2025
* Resource Edits, and Errors Flash (#59)

* changes

* Apply automatic changes

* Update app/Http/Controllers/ResourceEditsController.php

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Apply automatic changes

* Update resources/js/Components/NewsItem.vue

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Update resources/js/Components/NewsItem.vue

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Initial plan (#62)

Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>

* Initial plan (#63)

Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>

* Rename NewsItem component to TrendingResourceItem (#61)

* Initial plan

* Rename NewsItem.vue to TrendingResourceItem.vue and update all references

Co-authored-by: AllanKoder <74692833+AllanKoder@users.noreply.github.com>

---------

Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: AllanKoder <74692833+AllanKoder@users.noreply.github.com>

* Quick npm update

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <198982749+Copilot@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants