CSS Classes such as .js-{class} are applied to pure <input>, <textarea>, <select> elements
.js-input-focus
.parts-input
--focus
--value
Adds a --focus modifier to the parent .parts-input block when focusing, and --value when typing if the field is not empty
<div class="parts-input">
<input type="text" class="js-input-focus"/>
</div>
.js-input-number
Prevent entering any characters, except numbers.
<div class="parts-input">
<input type="text" class="js-input-number"/>
</div>
.js-input-phone
Only numbers and + symbol allowed
<div class="parts-input">
<input type="tel" class="js-input-phone"/>
</div>
.js-textarea-resize
Height change of textarea depending on the amount of text entered
<div class="parts-input">
<textarea class="js-textarea-resize"></textarea>
</div>
.js-input-limit
.parts-input
input
__counter
__total
Indication of a limited number of characters
<div class="parts-input">
<input type="text" class="js-input-limit" maxlength="20"/>
<div class="parts-input__note">
<span class="parts-input__counter"></span>
/
<span class="parts-input__total"></span>
</div>
</div>