Give some fixed width to the container of the textarea. E.g. 50px.
Set a long placeholder
Try adding and removing the text in textarea
Expected behaviour:
When the placeholder of textarea is long and wraps to next line, the height of the textarea should increase accordingly so that the placeholder is always visible.
Observed behaviour:
When the entered text wraps to next line, the height of the textarea increases automatically. But if the placeholder of textarea wraps to next line, it does not increase the height of the textarea, and the text overflows.
Workaround:
::before can be set to inputbox__highlighter class with the same content as the placeholder.
Suggestion:
Provide a boolean prop to enable or disable the height increase as per the placeholder text.
Steps to reproduce:
Expected behaviour: When the placeholder of textarea is long and wraps to next line, the height of the textarea should increase accordingly so that the placeholder is always visible.
Observed behaviour: When the entered text wraps to next line, the height of the textarea increases automatically. But if the placeholder of textarea wraps to next line, it does not increase the height of the textarea, and the text overflows.
Workaround: ::before can be set to
inputbox__highlighter
class with the same content as the placeholder.Suggestion: Provide a boolean prop to enable or disable the height increase as per the placeholder text.