docs: @NonNull public static Activity getActivity(@NonNull Context context) {
      if (context == null) {
        throw new NullPointerException("context == null");
      }
      if (context instanceof Activity) {
        return (Activity) context;
      }
  
      while (context instanceof ContextWrapper) {
        if (context instanceof Activity) {
          return (Activity) context;
        }
        context = ((ContextWrapper) context).getBaseContext();
      }
      throw new IllegalStateException("Could not find the surrounding Activity");
    }