Adding disableCaretPositioning option

This commit is contained in:
Francisco Hodge 2018-11-04 17:25:39 -05:00
parent 701db33ab1
commit 9abb36172d
5 changed files with 8 additions and 7 deletions

View File

@ -1,6 +1,6 @@
/*!
*
* simple-keyboard v2.7.7
* simple-keyboard v2.7.9
* https://github.com/hodgef/simple-keyboard
*
* Copyright (c) Francisco Hodge (https://github.com/hodgef)

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -1,6 +1,6 @@
{
"name": "simple-keyboard",
"version": "2.7.8",
"version": "2.7.9",
"description": "On-screen Javascript Virtual Keyboard",
"main": "build/index.js",
"scripts": {

View File

@ -516,8 +516,9 @@ class SimpleKeyboard {
let targetTagName = event.target.tagName.toLowerCase();
if(
targetTagName === "textarea" ||
targetTagName === "input"
(targetTagName === "textarea" ||
targetTagName === "input") &&
!this.options.disableCaretPositioning
){
/**
* Tracks current cursor position