{%- set type = (type is defined ? type : 'text') %}

{%- set class = [
	'text',
	(class is defined and class ? class : null),
	(placeholder is defined and placeholder ? 'nicetext' : null),
	(type is defined and type == 'password' ? 'password' : null),
	(disabled is defined and disabled ? 'disabled' : null),
	(size is defined and size ? null : 'fullwidth')
]|filter|join(' ') %}

{%- if showCharsLeft is defined and showCharsLeft and maxlength is defined and maxlength %}
	{%- set style = 'padding-'~(craft.i18n