unfocus method

Future<Online> unfocus(
  1. AbstractSelector selector, {
  2. bool show = true,
})

Implementation

Future<Online> unfocus(AbstractSelector selector, {bool show = true}) async {
  if (show) Show.unfocusing(selector.selector);
  var selected = selector is XPath
      ? await (await page).waitForXPath(selector.selector)
      : await (await page).waitForSelector(selector.selector);
  if (selected != null) {
    await selected.evaluate('''(element) => {
    element.blur();
  }''');
  }
  return this;
}