commonSize constant

int const commonSize

Number of tones in commonTones.

In original implementation package material_color_utilities this is defined as well, presumably for improved efficiency, there it is set to FlexTonalPalette.commonTones.length. Here we instead manually set it to compile time const of same const list length.

Flutter SDK TonalPalette has 13 common tones and FlexTonalPalette 15.

Starting from Flutter 3.22 and FlexSeedScheme 2.0.0 the common tones should be avoided and extended tones used instead. The common tones are kept for backwards compatibility and for cases where the original M3 palette is needed. The FlexPaletteType.extended is the new default for all FlexTones.

Implementation

static const int commonSize = 15;