<?php

use Jet\MVC_View;
use Jet\Form_Renderer_Field_Input;

/**
 * @var MVC_View $this
 * @var Form_Renderer_Field_Input $r
 */
$r = $this->getRaw( 'renderer' );
$field = $r->getField();

$r->setInputType('tel');

if( !$r->getBaseCssClasses() ) {
	$r->setBaseCssClass( 'form-control' );
}

if( $field->getLastErrorCode() ) {
	$r->addCustomCssClass( 'is-invalid' );
}
?>
<input <?=$r->renderTagAttributes()?>/>