Skip to content

feat(mix_generator): support plain MixWidget targets#997

Merged
leoafarias merged 1 commit into
mainfrom
feat/remix-mix-widget-target
Jul 24, 2026
Merged

feat(mix_generator): support plain MixWidget targets#997
leoafarias merged 1 commit into
mainfrom
feat/remix-mix-widget-target

Conversation

@leoafarias

@leoafarias leoafarias commented Jul 24, 2026

Copy link
Copy Markdown
Member

Related issue

No linked issue.

Description

Extend @MixWidget so Remix can generate wrappers around plain widget
constructors without requiring StyleWidget inheritance or a Styler extension
call() method.

Changes

  • Add MixWidget.target and independent factoryParameters selection.
  • Derive wrapper fields, defaults, keys, and generic parameters from the target
    constructor while excluding style and styleSpec.
  • Instantiate the target directly with the recipe result passed through
    style.
  • Preserve enum-derived named constructors, shared factory/target parameters,
    same-build generated Stylers, and the existing no-target path.
  • Bump the coordinated prereleases to mix_annotations 2.2.0-beta.1 and
    mix_generator 2.2.0-beta.2.

Review Checklist

  • Testing: Full mix_annotations and mix_generator test suites pass.
  • Breaking Changes: Existing @MixWidget behavior remains unchanged
    when target is omitted.
  • Documentation Updates: Annotation and generator READMEs and
    changelogs document the new API.
  • Website Updates: No website update is included.

Additional Information (optional)

The Remix integration was exercised against all 25 historical Fortal wrappers:
clean generation, Flutter analysis, and 1,889 Remix tests pass using these
unpublished package versions.

Downstream integration:

After this PR merges, publish the coordinated
mix_annotations 2.2.0-beta.1 and mix_generator 2.2.0-beta.2 prereleases.
Both Remix PRs intentionally remain draft until those versions resolve from
pub.dev and their CI jobs can be rerun.

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.

1 participant