changeVisibility static method

Future<void> changeVisibility(
  1. bool showBagde
)

change the reCaptcha badge visibility

Implementation

static Future<void> changeVisibility(bool showBagde) async {
  if (!kIsWeb) return;
  var badge = html.document.querySelector(".grecaptcha-badge");
  if (badge == null) return;
  badge.style.zIndex = "10";
  badge.style.visibility = showBagde ? "visible" : "hidden";
}