-
Notifications
You must be signed in to change notification settings - Fork 47
fix(mix): accept *ListMix on shadow styler methods so token refs work #932
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
base: main
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This handles direct
BoxShadowToken.mix()usage, but it does not preserve the existingBoxShadowListMixmerge semantics when the token-backed list is merged with a later literal list.I verified this with a focused failing widget test:
The resolved shadow keeps the later red color, but
blurRadiusbecomes0.0instead of preserving the token value4. During resolution,Propalso logs that it cannot convertList<BoxShadow>toMix<List<BoxShadow>>, so the token-resolved concrete list is skipped when Mix values are merged. The same issue reproduces forTextStyler.shadowswithShadowToken/List<Shadow>.Existing shadow-list tests already establish index-wise in-place merge behavior for literal lists, so token-backed list sources should keep that behavior too. Please add conversion/normalization for
List<BoxShadow>andList<Shadow>intoBoxShadowListMix/ShadowListMixduring mixed-source resolution, and add regression tests for token + literal list merges.