Skip to content

chore(skill): sync magic-framework with [Unreleased] features#80

Merged
anilcancakir merged 2 commits into
masterfrom
chore/skill-sync-alpha14
Apr 18, 2026
Merged

chore(skill): sync magic-framework with [Unreleased] features#80
anilcancakir merged 2 commits into
masterfrom
chore/skill-sync-alpha14

Conversation

@anilcancakir
Copy link
Copy Markdown
Contributor

Summary

Test plan

  • Skim SKILL.md — new canonical patterns section (FormRequest, Resource Routing, Async Validation, Session Flash) renders cleanly
  • Confirm each referenced symbol exists in master (EnumCast, ListCast, FormRequest, ResourceController, Gate.allowsAny, Session.old, etc.)
  • Remember to mirror these changes to the fluttersdk/ai repo (skills/magic-framework/ path) after merge

Update the magic-framework skill to cover the seven features merged on
top of 1.0.0-alpha.13: class-based casts (CastsAttributes, EnumCast,
ListCast) + json Map/List, Model.fill strict flag + MassAssignmentException,
FormRequest, MagicController.authorize + Gate.allowsAny/allowsAll,
MagicRoute.resource + ResourceController, AsyncRule + Unique, and the
Session facade with flash data + old()/error() helpers + MagicFormData
auto-flash on validation failure.
Copilot AI review requested due to automatic review settings April 18, 2026 14:09
@sentry
Copy link
Copy Markdown

sentry Bot commented Apr 18, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.

📢 Thoughts on this report? Let us know!

Copy link
Copy Markdown

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

Updates the Magic Framework skill and reference docs to reflect recently merged (post–1.0.0-alpha.13) framework features, including new Eloquent casting/mass-assignment behavior, validation additions (FormRequest + async rules), routing resource helpers, Gate convenience methods, and the new Session flash facade.

Changes:

  • Add/expand documentation for Session flash storage (Session, old()/error() helpers) and how it’s intended to be used with forms.
  • Document routing resource registration (MagicRoute.resource) and ResourceController.
  • Document validation + ORM additions: FormRequest, AsyncRule/Validator.validateAsync(), Unique, and class-based casts (CastsAttributes, EnumCast, ListCast) + fill(strict:).

Reviewed changes

Copilot reviewed 7 out of 7 changed files in this pull request and generated 12 comments.

Show a summary per file
File Description
skills/magic-framework/references/secondary-systems.md Adds Session flash-store documentation and usage/testing examples.
skills/magic-framework/references/routing-navigation.md Adds resource routing (MagicRoute.resource) and ResourceController docs.
skills/magic-framework/references/forms-validation.md Updates MagicFormData.validate() description; adds validateAsync(), FormRequest, and async rules/Unique docs.
skills/magic-framework/references/facades-api.md Adds Session facade API; adds Gate allowsAny/allowsAll; documents MagicRoute.resource.
skills/magic-framework/references/eloquent-orm.md Documents class-based casts, json Map/List casting, and fill(strict:) + MassAssignmentException.
skills/magic-framework/references/auth-system.md Documents Gate allowsAny/allowsAll and MagicController.authorize().
skills/magic-framework/SKILL.md Updates skill trigger text, facade count, canonical patterns/anti-patterns, and reference index.

Comment thread skills/magic-framework/references/secondary-systems.md
Comment thread skills/magic-framework/references/facades-api.md Outdated
Comment thread skills/magic-framework/references/routing-navigation.md Outdated
Comment thread skills/magic-framework/references/auth-system.md
Comment thread skills/magic-framework/SKILL.md Outdated
Comment thread skills/magic-framework/references/facades-api.md Outdated
Comment thread skills/magic-framework/SKILL.md Outdated
Comment thread skills/magic-framework/SKILL.md Outdated
Comment thread skills/magic-framework/references/forms-validation.md Outdated
Comment thread skills/magic-framework/references/auth-system.md Outdated
Fix six factual inaccuracies flagged by Copilot:
- Session.tick() is not wired automatically by the router; docs now show the explicit routerDelegate listener gated on currentLocation changes.
- MagicFormData.validate() only flashes form.data, not per-field errors; update every mention.
- Resource route slug preserves the normalized path (admin/users.index), no dash substitution.
- MagicController.authorize throws 'This action is unauthorized: $ability'.
- Add missing await on controller.destroy() example.
- Bump reference index entry from 17 to 18 facades.
@anilcancakir anilcancakir merged commit 3ee2683 into master Apr 18, 2026
2 checks passed
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