You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
const a =SnackBarThemeData(showCloseIcon:true);
final lerped =SnackBarThemeData.lerp(a, a.copyWith(elevation:4), 0.5);
print(lerped.showCloseIcon); // null
Expected results
showCloseIcon is true, like every other non-lerpable field in SnackBarThemeData.lerp (such as behavior and dismissDirection), which take a's value below t = 0.5 and b's value above it.
Actual results
showCloseIcon is always null, because SnackBarThemeData.lerp never passes it to the constructor.
ThemeData.lerp calls this method, so during an AnimatedTheme transition, such as switching between light and dark mode, a snack bar shown mid-animation loses the close icon its theme asked for.
Activity
saurabh-mirajkar commentedon Oct 27, 2026
@ChandraChaan Thanks for the report. Labelling for
team-designto investigate further.[material_ui] Fix SnackBarThemeData.lerp dropping showCloseIcon (flut…