$getProperty method

  1. @override
$Value? $getProperty(
  1. Runtime runtime,
  2. String identifier
)

Get a property by identifier on this instance

Implementation

@override
$Value? $getProperty(Runtime runtime, String identifier) {
  switch (identifier) {
    case 'useMaterial3':
      return $bool($value.useMaterial3);
    case 'primaryColor':
      return $Color.wrap($value.primaryColor);
    case 'primaryColorLight':
      return $Color.wrap($value.primaryColorLight);
    case 'primaryColorDark':
      return $Color.wrap($value.primaryColorDark);
    case 'canvasColor':
      return $Color.wrap($value.canvasColor);
    case 'scaffoldBackgroundColor':
      return $Color.wrap($value.scaffoldBackgroundColor);
    case 'cardColor':
      return $Color.wrap($value.cardColor);
    case 'dividerColor':
      return $Color.wrap($value.dividerColor);
    case 'highlightColor':
      return $Color.wrap($value.highlightColor);
    case 'splashColor':
      return $Color.wrap($value.splashColor);
    case 'selectedRowColor':
      return $Color.wrap(($value as dynamic).selectedRowColor);
    case 'unselectedWidgetColor':
      return $Color.wrap($value.unselectedWidgetColor);
    case 'disabledColor':
      return $Color.wrap($value.disabledColor);
    case 'buttonColor':
      return $Color.wrap(
          $value.buttonTheme.colorScheme?.primary ?? Colors.transparent);
    case 'secondaryHeaderColor':
      return $Color.wrap($value.secondaryHeaderColor);
    case 'textTheme':
      return $TextTheme.wrap($value.textTheme);
    case 'primaryTextTheme':
      return $TextTheme.wrap($value.primaryTextTheme);
  }
  throw UnimplementedError();
}