* Inserts shadow element after passed element where caret can be placed * * @param {Element} element - element after which shadow caret should be inserted
(element: Element)
| 345 | * @param {Element} element - element after which shadow caret should be inserted |
| 346 | */ |
| 347 | public createShadow(element: Element): void { |
| 348 | const shadowCaret = document.createElement('span'); |
| 349 | |
| 350 | shadowCaret.classList.add(Caret.CSS.shadowCaret); |
| 351 | element.insertAdjacentElement('beforeend', shadowCaret); |
| 352 | } |
| 353 | |
| 354 | /** |
| 355 | * Restores caret position |