add code comment/documentation

This commit is contained in:
Martin Raifer
2023-07-12 22:02:41 +02:00
parent 396d142623
commit 29b1197059
+2
View File
@@ -28,6 +28,8 @@ export function utilGetSetValue(selection, value, shouldUpdate) {
}
function stickyCursor(func) {
// only certain input element types allow manipulating the cursor
// see https://html.spec.whatwg.org/multipage/input.html#concept-input-apply
const supportedTypes = ['text', 'search', 'url', 'tel', 'password'];
return function() {
if (!supportedTypes.includes(this.type)) {