22 $params += [
'error' => null ];
23 parent::__construct( $params );
25 $this->key = $params[
'key'];
26 $this->error = $params[
'error'];
28 $this->mName =
'h-captcha-response';
35 $out = $this->mParent->getOutput();
39 "<script src=\"https://hcaptcha.com/1/api.js\" async defer></script>"
41 return Html::element(
'div', [
44 'mw-confirmedit-captcha-fail' => (
bool)$this->error,
46 'data-sitekey' => $this->key,
This class is a collection of static functions that serve two purposes: