When clicking on the div
at the end of the text, the div
gets focused but the caret doesn't appear (the caret appears in span.notContentEditable
and is not visible) (this issue occurs in Firefox/Vivaldi/(Chrome on Ubuntu 19.10))
div[name="comment"] {
-moz-appearance: textfield-multiline;
-webkit-appearance: textarea;
border: 1px solid gray;
font: medium -moz-fixed;
font: -webkit-small-control;
height: 100px;
width: 100%;
overflow: auto;
padding: 5px;
resize: both;
margin-bottom: 5px;
}
.bold {
font-weight: bold;
}
<div name="comment" contenteditable="true">
<span class="bold" contenteditable="false">spantext</span>
</div>