of static method

Zeta of(
  1. BuildContext context
)

Fetches the Zeta instance from the provided context.

It ensures that the context has access to the Zeta theming information. Throws a FlutterError if the Zeta is not found in the widget tree.

Implementation

static Zeta of(BuildContext context) {
  final defaults = context.dependOnInheritedWidgetOfExactType<Zeta>();
  if (defaults != null) {
    return defaults;
  } else {
    return defaultZetaValues(context);
  }
}