@@ -167,7 +167,8 @@ public AutumnTonalSkin() {
167
167
.onContainerVariant (DynamicScheme ::getTonalContainerOutlineVariant )
168
168
.build ())
169
169
// For muted containers (enabled controls), use tonal outlines for border
170
- // consistency with active controls, and softer text / icon colors
170
+ // consistency with active controls, and softer text / icon colors. Also use
171
+ // higher alpha values for disabled controls for better contrast.
171
172
.mutedContainerResolverOverlay (
172
173
SchemeContainerColorsResolverOverlay .builder ()
173
174
.containerOutline (DynamicScheme ::getTonalContainerOutline )
@@ -178,12 +179,13 @@ public AutumnTonalSkin() {
178
179
.onContainerDisabledAlpha ((s ) -> 0.6f )
179
180
.containerOutlineDisabledAlpha ((s ) -> 0.55f )
180
181
.build ())
181
- // For tonal containers (active controls), use softer text / icon colors
182
+ // For tonal containers (active controls), use softer text / icon colors.
183
+ // Also use higher alpha values for disabled controls for better contrast.
182
184
.tonalContainerResolverOverlay (
183
185
SchemeContainerColorsResolverOverlay .builder ()
184
186
.onContainer (DynamicScheme ::getTonalContainerOutline )
185
187
.onContainerVariant (DynamicScheme ::getTonalContainerOutlineVariant )
186
- .containerSurfaceDisabledAlpha ((s ) -> 0.5f )
188
+ .containerSurfaceDisabledAlpha ((s ) -> 0.4f )
187
189
.onContainerDisabledAlpha ((s ) -> 0.6f )
188
190
.containerOutlineDisabledAlpha ((s ) -> 0.55f )
189
191
.build ())
@@ -201,14 +203,15 @@ public AutumnTonalSkin() {
201
203
// Custom visuals for controls in selected state:
202
204
// 1. Deeper container surfaces (more saturated seed in fidelity mode)
203
205
// 2. Softer on container, mapped to container outline (used for texts and icons)
206
+ // 3. Higher alpha values for disabled controls for better contrast
204
207
autumnDefaultBundle .registerContainerTokens (ColorSchemeUtils .getContainerTokens (
205
208
/* seed */ Hct .fromInt (0xFFFDBD72 ),
206
209
/* isFidelity */ true ,
207
210
/* isDark */ false ,
208
211
/* colorResolver */ PaletteResolverUtils .getPaletteTonalColorResolver ().overlayWith (
209
212
PaletteContainerColorsResolverOverlay .builder ()
210
213
.onContainer (DynamicPalette ::getTonalContainerOutline )
211
- .containerSurfaceDisabledAlpha ((s ) -> 0.5f )
214
+ .containerSurfaceDisabledAlpha ((s ) -> 0.4f )
212
215
.onContainerDisabledAlpha ((s ) -> 0.6f )
213
216
.containerOutlineDisabledAlpha ((s ) -> 0.55f )
214
217
.build ())),
0 commit comments