protected function renderElement($field)
    {
        $type = $field['type'];
        switch ($type) {
            case 'textarea':
            case 'markup':
            case 'select':
            case 'radio':
            case 'checkbox':
                return $this->$type($field);
            default:
                return $this->input($field);
        }
    }