material-foundation / material-color-utilities

Color libraries for Material You
Apache License 2.0
1.57k stars 134 forks source link

Wrong chroma for neutral colors #114

Closed MrEbbinghaus closed 8 months ago

MrEbbinghaus commented 10 months ago

The blog post Introducing Tone-based Surfaces in Material 3 from March states:

The chroma for the neutral palette is increased from 4 to 6

This isn't reflected in any of the applications.

Is there a document where these values are noted? A single source of truth? https://m3.material.io/styles/color/the-color-system doesn't mention any chroma values.


https://github.com/material-foundation/material-color-utilities/blob/12b75a01476c41bb2ba9c585cfc71f1a7692aa11/typescript/palettes/core_palette.ts#L111

https://github.com/material-foundation/material-color-utilities/blob/12b75a01476c41bb2ba9c585cfc71f1a7692aa11/swift/Sources/MaterialColorUtilities/Palettes/CorePalette.swift#L70

https://github.com/material-foundation/material-color-utilities/blob/12b75a01476c41bb2ba9c585cfc71f1a7692aa11/java/palettes/CorePalette.java#L62

https://github.com/material-foundation/material-color-utilities/blob/12b75a01476c41bb2ba9c585cfc71f1a7692aa11/cpp/palettes/core.cc#L41

https://github.com/material-foundation/material-color-utilities/blob/12b75a01476c41bb2ba9c585cfc71f1a7692aa11/dart/lib/palettes/core_palette.dart#L57

MrEbbinghaus commented 10 months ago

Just noticed that the other remarks from the blogpost aren't reflected either. Do you want new issues for this or should I update this one?

The default light theme surface role from tone 99 to tone 98

https://github.com/material-foundation/material-color-utilities/blob/12b75a01476c41bb2ba9c585cfc71f1a7692aa11/typescript/scheme/scheme.ts#L197

Surface roles in dark theme are slightly darkened

image

https://github.com/material-foundation/material-color-utilities/blob/12b75a01476c41bb2ba9c585cfc71f1a7692aa11/typescript/scheme/scheme.ts#L234

MrHBS commented 9 months ago

cc @guidezpl

guidezpl commented 9 months ago

cc @pennzht

pennzht commented 8 months ago

Thank you for your message.

Please switch to use SchemeTonalSpot (scheme_tonal_spot.dart) instead; it is up to date.

make_schemes.md contains a guidance on how to use MaterialDynamicColors and DynamicScheme.

We'll consider updating scheme.dart too.

MrEbbinghaus commented 8 months ago

@pennzht Thank you. So, the Dart implementation is considered the reference?

Nevertheless, it would be great to have a single spec instead of reference implementations.

This would allow designers and devs to use/implement material color themselves, without needing to work through the code to understand what colors are generated in which way.