public function get(Theme $theme)
{
$form = $this->get_form();
if ($this->has_errors) {
$this->node->add_class('_has_error');
$error_output = $this->error_wrap('', $this->errors);
$form->dom->find('[data-control-errors="' . $this->name . '"]')->append_html($error_output);
$form->dom->find('[data-form-success]')->remove();
} else {
$form->dom->find('[data-control-errors="' . $this->name . '"]')->remove();
$form->dom->find('[data-show-on-error="' . $this->name . '"]')->promote_children();
$form->dom->find('[data-show-on-error="' . $this->name . '"]')->remove();
}
if (!$form->submitted) {
$form->dom->find('[data-form-success]')->remove();
}
return '';
}