How do I add span tag for selected text in a group of text using Angular JS.
Html:
<div class="container" #contents
[attr.contenteditable]="contenteditable"
(click)="changeContenteditable($event)"
(mousemove)="showSelectedText($event)">
Lorem Ipsum is simply dummied text of the printing and typesetting industry. Lorem Ipsum has been the industry's
</div>
If I select Lorem Ipsum, it should wrapped by span element.
How do I achieve this in angular 7