Here is the BlackSheep answer a little adapted to SCSS with Bootstrap variables for styling & sizes, and a specific class to target only textareas
$textarea-floating-label-pseudo-element-height: (
$form-floating-input-padding-t + ($font-size-base * $line-height-base)
) * 0.85 - $form-floating-padding-y;
// look at $form-floating-label-transform for "0.85"
.form-floating-textarea {
position: relative;
&:before {
content: "";
position: absolute;
top: $input-border-width;
left: $input-border-width;
width: calc(100% - $spacer); /* to show scrollbar */
height: $textarea-floating-label-pseudo-element-height;
border-radius: $input-border-radius;
background-color: $input-bg;
}
&.form-control:focus,
&.form-control:not(:placeholder-shown) {
padding-top: $textarea-floating-label-pseudo-element-height + ($form-floating-padding-y * 0.5); /* leave a little more space below the label */
}
}
This will look like that :
