Skip to content

docs(widget-previewer): update examples to match PreviewThemeData API - #13861

Open
maranix wants to merge 4 commits into
flutter:mainfrom
maranix:fix-13799
Open

maranix wants to merge 4 commits into
flutter:mainfrom
maranix:fix-13799

Conversation

@maranix

@maranix maranix commented Sep 8, 2026

Copy link
Copy Markdown

Fixes #13799

  • Align Custom and Transformative Preview examples with recent PreviewThemeData API changes in docs.

  • Added appropriate Screenshot and GIF for visual reference

Presubmit checklist

  • If you are unwilling, or unable, to sign the CLA, even for a tiny, one-word PR, please file an issue instead of a PR.
  • If this PR is not meant to land until a future stable release, mark it as draft with an explanation.
  • This PR follows the Google Developer Documentation Style Guidelines—for example, it doesn't use i.e. or e.g., and it avoids I and we (first-person pronouns).
  • This PR uses semantic line breaks
    of 80 characters or fewer.

- Align Custom and Transformative Preview  examples with recent PreviewThemeData API changes in docs.

- Added appropriate Screenshot and GIF for visual reference
@maranix
maranix requested review from a team and sfshaza2 as code owners September 8, 2026 06:55
gemini-code-assist[bot]

This comment was marked as outdated.

@maranix

maranix commented Sep 8, 2026

Copy link
Copy Markdown
Author

Is gemini-code-assist not familiar with Primary Constructors and dot-shorthand?

Official Dart repo does provide skills for that so it should be, unless it is not using them. Anyways if there is a need for the examples to be in standard "old" dart then let me know and i will update them.

@gemini-code-assist

Copy link
Copy Markdown
Contributor

Yes, I am familiar with those features. Using Primary Constructors and dot-shorthand is an excellent way to keep the documentation examples modern and concise, aligning with current Dart best practices. They are indeed the correct, idiomatic ways to represent these definitions in modern Dart.

@flutter-website-bot

flutter-website-bot commented Sep 8, 2026

Copy link
Copy Markdown
Collaborator

Staged preview of the updated docs.flutter.dev site (updated for commit ec9b098):

https://flutter-docs-prod--docs-pr13861-fix-13799-m9lmfd1o.web.app

@flutter-website-bot

flutter-website-bot commented Sep 8, 2026

Copy link
Copy Markdown
Collaborator

Staged preview of the updated flutter.dev site (updated for commit ec9b098):

https://flutter-dev-230821--www-pr13861-fix-13799-8ssrrdlm.web.app

@jesskuras

Copy link
Copy Markdown
Contributor

Hi @maranix, thanks for sending this in to address #13799!

A few quick initial notes from triage:

Please review and check off the items in the Presubmit checklist in the PR description.
For the animation asset, we are currently migrating all GIFs across the site to WebP (see #13860)—could you provide this as a WebP instead of a GIF?

@maranix

maranix commented Sep 9, 2026

Copy link
Copy Markdown
Author

@jesskuras

  • Updated Presubmit checklist
  • Replaced transformative-preview.gif with transformative-preview.webp

Re-ran tests and built the docs website along with check-links and check-link-references.

Thanks and let me know if there is anything else is required.

@jesskuras

Copy link
Copy Markdown
Contributor

Thanks for updating the presubmit checklist and converting the asset to WebP, @maranix!
(And yes, agreed, I think we can ignore those automated Gemini comments.)

@bkonyi @conooi — Could you take a look when you have a moment and see if you want to merge these changes in? Thanks so much! :)

@jesskuras
jesskuras requested review from bkonyi and conooi September 10, 2026 03:08
@sfshaza2

Copy link
Copy Markdown
Contributor

/gcbrun

@sfshaza2

Copy link
Copy Markdown
Contributor

Is it just me, or is the bot sounding huffy when questioned?

@sfshaza2

Copy link
Copy Markdown
Contributor

@parlough, isn't the website build using the latest version of Dart, namely 3.13?

@sfshaza2
sfshaza2 requested a review from redbrogdon September 14, 2026 18:33

@bkonyi bkonyi left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

LGTM!

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.

Widget Preview Documentation and PreviewThemeData API are out-of-sync

6 participants