getError method

Color getError()

Return primary colour's light or dark theme colour according to mode.

Implementation

Color getError() {
  return mode == PaletteThemeModes.dark ? error.dark : error.light;
}