From 5c192a10f6cb0a792833586387afbfa5308371fa Mon Sep 17 00:00:00 2001 From: Francisco Hodge Date: Thu, 6 Feb 2020 23:46:27 -0500 Subject: [PATCH] Updating to simple-keyboard v2.28 --- build/css/index.css | 6 +++--- build/css/index.css.map | 2 +- build/index.js | 4 ++-- build/index.js.map | 2 +- package-lock.json | 8 ++++---- package.json | 4 ++-- 6 files changed, 13 insertions(+), 13 deletions(-) diff --git a/build/css/index.css b/build/css/index.css index 7ce30cba9..9faab6c26 100644 --- a/build/css/index.css +++ b/build/css/index.css @@ -1,6 +1,6 @@ /*! * - * react-simple-keyboard v2.1.117 + * react-simple-keyboard v2.2.0 * https://github.com/hodgef/react-simple-keyboard * * Copyright (c) Francisco Hodge (https://github.com/hodgef) @@ -11,7 +11,7 @@ */ /*! * - * simple-keyboard v2.27.86 + * simple-keyboard v2.28.2 * https://github.com/hodgef/simple-keyboard * * Copyright (c) Francisco Hodge (https://github.com/hodgef) @@ -19,5 +19,5 @@ * This source code is licensed under the MIT license found in the * LICENSE file in the root directory of this source tree. * - */body,html{margin:0;padding:0}.simple-keyboard{font-family:HelveticaNeue-Light,Helvetica Neue Light,Helvetica Neue,Helvetica,Arial,Lucida Grande,sans-serif;width:100%;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;box-sizing:border-box;overflow:hidden;touch-action:manipulation}.simple-keyboard .hg-row{display:flex}.simple-keyboard .hg-row:not(:last-child){margin-bottom:5px}.simple-keyboard .hg-row .hg-button-container,.simple-keyboard .hg-row .hg-button:not(:last-child){margin-right:5px}.simple-keyboard .hg-row>div:last-child{margin-right:0}.simple-keyboard .hg-row .hg-button-container{display:flex}.simple-keyboard .hg-button{display:inline-block;flex-grow:1;cursor:pointer}.simple-keyboard .hg-button span{pointer-events:none}.simple-keyboard.hg-theme-default{background-color:rgba(0,0,0,.1);padding:5px;border-radius:5px}.simple-keyboard.hg-theme-default .hg-button{box-shadow:0 0 3px -1px rgba(0,0,0,.3);height:40px;border-radius:5px;box-sizing:border-box;padding:5px;background:#fff;border-bottom:1px solid #b5b5b5;cursor:pointer;display:flex;align-items:center;justify-content:center;-webkit-tap-highlight-color:rgba(0,0,0,0)}.simple-keyboard.hg-theme-default .hg-button.hg-activeButton{background:#efefef}.simple-keyboard button.hg-button{border-width:0;outline:0;font-size:inherit}.simple-keyboard.hg-theme-default.hg-layout-numeric .hg-button{width:33.3%;height:60px;align-items:center;display:flex;justify-content:center}.simple-keyboard.hg-theme-default .hg-button.hg-button-numpadadd,.simple-keyboard.hg-theme-default .hg-button.hg-button-numpadenter{height:85px}.simple-keyboard.hg-theme-default .hg-button.hg-button-numpad0{width:105px}.simple-keyboard.hg-theme-default .hg-button.hg-button-com{max-width:85px}.simple-keyboard.hg-theme-default .hg-button.hg-standardBtn.hg-button-at{max-width:45px}.simple-keyboard.hg-theme-default .hg-button.hg-selectedButton{background:rgba(5,25,70,.53);color:#fff}.simple-keyboard.hg-theme-default .hg-button.hg-standardBtn[data-skbtn=".com"]{max-width:82px}.simple-keyboard.hg-theme-default .hg-button.hg-standardBtn[data-skbtn="@"]{max-width:60px} + */.hg-theme-default{width:100%;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;box-sizing:border-box;overflow:hidden;touch-action:manipulation}.hg-theme-default .hg-button span{pointer-events:none}.hg-theme-default button.hg-button{border-width:0;outline:0;font-size:inherit}.hg-theme-default{font-family:HelveticaNeue-Light,Helvetica Neue Light,Helvetica Neue,Helvetica,Arial,Lucida Grande,sans-serif;background-color:rgba(0,0,0,.1);padding:5px;border-radius:5px}.hg-theme-default .hg-button{display:inline-block;flex-grow:1}.hg-theme-default .hg-row{display:flex}.hg-theme-default .hg-row:not(:last-child){margin-bottom:5px}.hg-theme-default .hg-row .hg-button-container,.hg-theme-default .hg-row .hg-button:not(:last-child){margin-right:5px}.hg-theme-default .hg-row>div:last-child{margin-right:0}.hg-theme-default .hg-row .hg-button-container{display:flex}.hg-theme-default .hg-button{box-shadow:0 0 3px -1px rgba(0,0,0,.3);height:40px;border-radius:5px;box-sizing:border-box;padding:5px;background:#fff;border-bottom:1px solid #b5b5b5;cursor:pointer;display:flex;align-items:center;justify-content:center;-webkit-tap-highlight-color:rgba(0,0,0,0)}.hg-theme-default .hg-button.hg-activeButton{background:#efefef}.hg-theme-default.hg-layout-numeric .hg-button{width:33.3%;height:60px;align-items:center;display:flex;justify-content:center}.hg-theme-default .hg-button.hg-button-numpadadd,.hg-theme-default .hg-button.hg-button-numpadenter{height:85px}.hg-theme-default .hg-button.hg-button-numpad0{width:105px}.hg-theme-default .hg-button.hg-button-com{max-width:85px}.hg-theme-default .hg-button.hg-standardBtn.hg-button-at{max-width:45px}.hg-theme-default .hg-button.hg-selectedButton{background:rgba(5,25,70,.53);color:#fff}.hg-theme-default .hg-button.hg-standardBtn[data-skbtn=".com"]{max-width:82px}.hg-theme-default .hg-button.hg-standardBtn[data-skbtn="@"]{max-width:60px} /*# sourceMappingURL=index.css.map */ \ No newline at end of file diff --git a/build/css/index.css.map b/build/css/index.css.map index 9c8bcb65c..bea1b401c 100644 --- a/build/css/index.css.map +++ b/build/css/index.css.map @@ -1 +1 @@ -{"version":3,"sources":["index.css","/home/runner/work/react-simple-keyboard/react-simple-keyboard/node_modules/simple-keyboard/build/css/index.css","/home/runner/work/simple-keyboard/simple-keyboard/src/lib/components/Keyboard.css"],"names":[],"mappings":"AAAA;;;;;;;;;;EAUE;ACVF;;;;;;;;;;EAUE,CCVF,UAEE,QAAS,CACT,SACF,CAEA,iBACE,4GAC+C,CAC/C,UAAW,CACX,wBAAiB,CAAjB,qBAAiB,CAAjB,oBAAiB,CAAjB,gBAAiB,CACjB,qBAAsB,CACtB,eAAgB,CAChB,yBACF,CAEA,yBACE,YACF,CAEA,0CACE,iBACF,CAMA,mGACE,gBACF,CAEA,wCACE,cACF,CAEA,8CACE,YACF,CAEA,4BACE,oBAAqB,CACrB,WAAY,CACZ,cACF,CAEA,iCACE,mBACF,CAKA,kCACE,+BAAoC,CACpC,WAAY,CACZ,iBACF,CAEA,6CACE,sCAA+C,CAC/C,WAAY,CACZ,iBAAkB,CAClB,qBAAsB,CACtB,WAAY,CACZ,eAAiB,CACjB,+BAAgC,CAChC,cAAe,CACf,YAAa,CACb,kBAAmB,CACnB,sBAAuB,CACvB,yCACF,CAEA,6DACE,kBACF,CAGA,kCACE,cAAe,CACf,SAAU,CACV,iBACF,CAEA,+DACE,WAAY,CACZ,WAAY,CACZ,kBAAmB,CACnB,YAAa,CACb,sBACF,CAMA,oIACE,WACF,CAEA,+DACE,WACF,CAEA,2DACE,cACF,CAEA,yEACE,cACF,CAEA,+DACE,4BAAiC,CACjC,UACF,CAEA,+EACE,cACF,CAEA,4EACE,cACF","file":"index.css","sourcesContent":["/*!\n * \n * react-simple-keyboard v2.1.117\n * https://github.com/hodgef/react-simple-keyboard\n * \n * Copyright (c) Francisco Hodge (https://github.com/hodgef)\n * \n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n * \n */\n/*!\n * \n * simple-keyboard v2.27.86\n * https://github.com/hodgef/simple-keyboard\n * \n * Copyright (c) Francisco Hodge (https://github.com/hodgef)\n * \n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n * \n */body,html{margin:0;padding:0}.simple-keyboard{font-family:HelveticaNeue-Light,Helvetica Neue Light,Helvetica Neue,Helvetica,Arial,Lucida Grande,sans-serif;width:100%;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;box-sizing:border-box;overflow:hidden;touch-action:manipulation}.simple-keyboard .hg-row{display:flex}.simple-keyboard .hg-row:not(:last-child){margin-bottom:5px}.simple-keyboard .hg-row .hg-button-container,.simple-keyboard .hg-row .hg-button:not(:last-child){margin-right:5px}.simple-keyboard .hg-row>div:last-child{margin-right:0}.simple-keyboard .hg-row .hg-button-container{display:flex}.simple-keyboard .hg-button{display:inline-block;flex-grow:1;cursor:pointer}.simple-keyboard .hg-button span{pointer-events:none}.simple-keyboard.hg-theme-default{background-color:rgba(0,0,0,.1);padding:5px;border-radius:5px}.simple-keyboard.hg-theme-default .hg-button{box-shadow:0 0 3px -1px rgba(0,0,0,.3);height:40px;border-radius:5px;box-sizing:border-box;padding:5px;background:#fff;border-bottom:1px solid #b5b5b5;cursor:pointer;display:flex;align-items:center;justify-content:center;-webkit-tap-highlight-color:rgba(0,0,0,0)}.simple-keyboard.hg-theme-default .hg-button.hg-activeButton{background:#efefef}.simple-keyboard button.hg-button{border-width:0;outline:0;font-size:inherit}.simple-keyboard.hg-theme-default.hg-layout-numeric .hg-button{width:33.3%;height:60px;align-items:center;display:flex;justify-content:center}.simple-keyboard.hg-theme-default .hg-button.hg-button-numpadadd,.simple-keyboard.hg-theme-default .hg-button.hg-button-numpadenter{height:85px}.simple-keyboard.hg-theme-default .hg-button.hg-button-numpad0{width:105px}.simple-keyboard.hg-theme-default .hg-button.hg-button-com{max-width:85px}.simple-keyboard.hg-theme-default .hg-button.hg-standardBtn.hg-button-at{max-width:45px}.simple-keyboard.hg-theme-default .hg-button.hg-selectedButton{background:rgba(5,25,70,.53);color:#fff}.simple-keyboard.hg-theme-default .hg-button.hg-standardBtn[data-skbtn=\".com\"]{max-width:82px}.simple-keyboard.hg-theme-default .hg-button.hg-standardBtn[data-skbtn=\"@\"]{max-width:60px}\n/*# sourceMappingURL=index.css.map */\n","/*!\n * \n * simple-keyboard v2.27.86\n * https://github.com/hodgef/simple-keyboard\n * \n * Copyright (c) Francisco Hodge (https://github.com/hodgef)\n * \n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n * \n */\nbody,\nhtml {\n margin: 0;\n padding: 0;\n}\n\n.simple-keyboard {\n font-family: \"HelveticaNeue-Light\", \"Helvetica Neue Light\", \"Helvetica Neue\",\n Helvetica, Arial, \"Lucida Grande\", sans-serif;\n width: 100%;\n -webkit-user-select: none;\n -moz-user-select: none;\n -ms-user-select: none;\n user-select: none;\n box-sizing: border-box;\n overflow: hidden;\n touch-action: manipulation;\n}\n\n.simple-keyboard .hg-row {\n display: flex;\n}\n\n.simple-keyboard .hg-row:not(:last-child) {\n margin-bottom: 5px;\n}\n\n.simple-keyboard .hg-row .hg-button:not(:last-child) {\n margin-right: 5px;\n}\n\n.simple-keyboard .hg-row .hg-button-container {\n margin-right: 5px;\n}\n\n.simple-keyboard .hg-row > div:last-child {\n margin-right: 0;\n}\n\n.simple-keyboard .hg-row .hg-button-container {\n display: flex;\n}\n\n.simple-keyboard .hg-button {\n display: inline-block;\n flex-grow: 1;\n cursor: pointer;\n}\n\n.simple-keyboard .hg-button span {\n pointer-events: none;\n}\n\n/**\n * hg-theme-default theme\n */\n.simple-keyboard.hg-theme-default {\n background-color: rgba(0, 0, 0, 0.1);\n padding: 5px;\n border-radius: 5px;\n}\n\n.simple-keyboard.hg-theme-default .hg-button {\n box-shadow: 0px 0px 3px -1px rgba(0, 0, 0, 0.3);\n height: 40px;\n border-radius: 5px;\n box-sizing: border-box;\n padding: 5px;\n background: white;\n border-bottom: 1px solid #b5b5b5;\n cursor: pointer;\n display: flex;\n align-items: center;\n justify-content: center;\n -webkit-tap-highlight-color: rgba(0, 0, 0, 0);\n}\n\n.simple-keyboard.hg-theme-default .hg-button.hg-activeButton {\n background: #efefef;\n}\n\n/* When using option \"useButtonTag\" */\n.simple-keyboard button.hg-button {\n border-width: 0;\n outline: 0;\n font-size: inherit;\n}\n\n.simple-keyboard.hg-theme-default.hg-layout-numeric .hg-button {\n width: 33.3%;\n height: 60px;\n align-items: center;\n display: flex;\n justify-content: center;\n}\n\n.simple-keyboard.hg-theme-default .hg-button.hg-button-numpadadd {\n height: 85px;\n}\n\n.simple-keyboard.hg-theme-default .hg-button.hg-button-numpadenter {\n height: 85px;\n}\n\n.simple-keyboard.hg-theme-default .hg-button.hg-button-numpad0 {\n width: 105px;\n}\n\n.simple-keyboard.hg-theme-default .hg-button.hg-button-com {\n max-width: 85px;\n}\n\n.simple-keyboard.hg-theme-default .hg-button.hg-standardBtn.hg-button-at {\n max-width: 45px;\n}\n\n.simple-keyboard.hg-theme-default .hg-button.hg-selectedButton {\n background: rgba(5, 25, 70, 0.53);\n color: white;\n}\n\n.simple-keyboard.hg-theme-default .hg-button.hg-standardBtn[data-skbtn=\".com\"] {\n max-width: 82px;\n}\n\n.simple-keyboard.hg-theme-default .hg-button.hg-standardBtn[data-skbtn=\"@\"] {\n max-width: 60px;\n}\n\n","body,\nhtml {\n margin: 0;\n padding: 0;\n}\n\n.simple-keyboard {\n font-family: \"HelveticaNeue-Light\", \"Helvetica Neue Light\", \"Helvetica Neue\",\n Helvetica, Arial, \"Lucida Grande\", sans-serif;\n width: 100%;\n user-select: none;\n box-sizing: border-box;\n overflow: hidden;\n touch-action: manipulation;\n}\n\n.simple-keyboard .hg-row {\n display: flex;\n}\n\n.simple-keyboard .hg-row:not(:last-child) {\n margin-bottom: 5px;\n}\n\n.simple-keyboard .hg-row .hg-button:not(:last-child) {\n margin-right: 5px;\n}\n\n.simple-keyboard .hg-row .hg-button-container {\n margin-right: 5px;\n}\n\n.simple-keyboard .hg-row > div:last-child {\n margin-right: 0;\n}\n\n.simple-keyboard .hg-row .hg-button-container {\n display: flex;\n}\n\n.simple-keyboard .hg-button {\n display: inline-block;\n flex-grow: 1;\n cursor: pointer;\n}\n\n.simple-keyboard .hg-button span {\n pointer-events: none;\n}\n\n/**\n * hg-theme-default theme\n */\n.simple-keyboard.hg-theme-default {\n background-color: rgba(0, 0, 0, 0.1);\n padding: 5px;\n border-radius: 5px;\n}\n\n.simple-keyboard.hg-theme-default .hg-button {\n box-shadow: 0px 0px 3px -1px rgba(0, 0, 0, 0.3);\n height: 40px;\n border-radius: 5px;\n box-sizing: border-box;\n padding: 5px;\n background: white;\n border-bottom: 1px solid #b5b5b5;\n cursor: pointer;\n display: flex;\n align-items: center;\n justify-content: center;\n -webkit-tap-highlight-color: rgba(0, 0, 0, 0);\n}\n\n.simple-keyboard.hg-theme-default .hg-button.hg-activeButton {\n background: #efefef;\n}\n\n/* When using option \"useButtonTag\" */\n.simple-keyboard button.hg-button {\n border-width: 0;\n outline: 0;\n font-size: inherit;\n}\n\n.simple-keyboard.hg-theme-default.hg-layout-numeric .hg-button {\n width: 33.3%;\n height: 60px;\n align-items: center;\n display: flex;\n justify-content: center;\n}\n\n.simple-keyboard.hg-theme-default .hg-button.hg-button-numpadadd {\n height: 85px;\n}\n\n.simple-keyboard.hg-theme-default .hg-button.hg-button-numpadenter {\n height: 85px;\n}\n\n.simple-keyboard.hg-theme-default .hg-button.hg-button-numpad0 {\n width: 105px;\n}\n\n.simple-keyboard.hg-theme-default .hg-button.hg-button-com {\n max-width: 85px;\n}\n\n.simple-keyboard.hg-theme-default .hg-button.hg-standardBtn.hg-button-at {\n max-width: 45px;\n}\n\n.simple-keyboard.hg-theme-default .hg-button.hg-selectedButton {\n background: rgba(5, 25, 70, 0.53);\n color: white;\n}\n\n.simple-keyboard.hg-theme-default .hg-button.hg-standardBtn[data-skbtn=\".com\"] {\n max-width: 82px;\n}\n\n.simple-keyboard.hg-theme-default .hg-button.hg-standardBtn[data-skbtn=\"@\"] {\n max-width: 60px;\n}\n"]} \ No newline at end of file +{"version":3,"sources":["index.css","C:/Dev/react-simple-keyboard/node_modules/simple-keyboard/build/css/index.css","C:/home/runner/work/simple-keyboard/simple-keyboard/src/lib/components/Keyboard.css"],"names":[],"mappings":"AAAA;;;;;;;;;;EAUE;ACVF;;;;;;;;;;EAUE,CCNF,kBACE,UAAW,CACX,wBAAiB,CAAjB,qBAAiB,CAAjB,oBAAiB,CAAjB,gBAAiB,CACjB,qBAAsB,CACtB,eAAgB,CAChB,yBACF,CAEA,kCACE,mBACF,CAGA,mCACE,cAAe,CACf,SAAU,CACV,iBACF,CAEA,kBACE,4GAC+C,CAC/C,+BAAoC,CACpC,WAAY,CACZ,iBACF,CAEA,6BACE,oBAAqB,CACrB,WAEF,CAEA,0BACE,YACF,CAEA,2CACE,iBACF,CAMA,qGACE,gBACF,CAEA,yCACE,cACF,CAEA,+CACE,YACF,CAEA,6BACE,sCAA+C,CAC/C,WAAY,CACZ,iBAAkB,CAClB,qBAAsB,CACtB,WAAY,CACZ,eAAiB,CACjB,+BAAgC,CAChC,cAAe,CACf,YAAa,CACb,kBAAmB,CACnB,sBAAuB,CACvB,yCACF,CAEA,6CACE,kBACF,CAEA,+CACE,WAAY,CACZ,WAAY,CACZ,kBAAmB,CACnB,YAAa,CACb,sBACF,CAMA,oGACE,WACF,CAEA,+CACE,WACF,CAEA,2CACE,cACF,CAEA,yDACE,cACF,CAEA,+CACE,4BAAiC,CACjC,UACF,CAEA,+DACE,cACF,CAEA,4DACE,cACF","file":"index.css","sourcesContent":["/*!\n * \n * react-simple-keyboard v2.2.0\n * https://github.com/hodgef/react-simple-keyboard\n * \n * Copyright (c) Francisco Hodge (https://github.com/hodgef)\n * \n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n * \n */\n/*!\n * \n * simple-keyboard v2.28.2\n * https://github.com/hodgef/simple-keyboard\n * \n * Copyright (c) Francisco Hodge (https://github.com/hodgef)\n * \n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n * \n */.hg-theme-default{width:100%;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;box-sizing:border-box;overflow:hidden;touch-action:manipulation}.hg-theme-default .hg-button span{pointer-events:none}.hg-theme-default button.hg-button{border-width:0;outline:0;font-size:inherit}.hg-theme-default{font-family:HelveticaNeue-Light,Helvetica Neue Light,Helvetica Neue,Helvetica,Arial,Lucida Grande,sans-serif;background-color:rgba(0,0,0,.1);padding:5px;border-radius:5px}.hg-theme-default .hg-button{display:inline-block;flex-grow:1}.hg-theme-default .hg-row{display:flex}.hg-theme-default .hg-row:not(:last-child){margin-bottom:5px}.hg-theme-default .hg-row .hg-button-container,.hg-theme-default .hg-row .hg-button:not(:last-child){margin-right:5px}.hg-theme-default .hg-row>div:last-child{margin-right:0}.hg-theme-default .hg-row .hg-button-container{display:flex}.hg-theme-default .hg-button{box-shadow:0 0 3px -1px rgba(0,0,0,.3);height:40px;border-radius:5px;box-sizing:border-box;padding:5px;background:#fff;border-bottom:1px solid #b5b5b5;cursor:pointer;display:flex;align-items:center;justify-content:center;-webkit-tap-highlight-color:rgba(0,0,0,0)}.hg-theme-default .hg-button.hg-activeButton{background:#efefef}.hg-theme-default.hg-layout-numeric .hg-button{width:33.3%;height:60px;align-items:center;display:flex;justify-content:center}.hg-theme-default .hg-button.hg-button-numpadadd,.hg-theme-default .hg-button.hg-button-numpadenter{height:85px}.hg-theme-default .hg-button.hg-button-numpad0{width:105px}.hg-theme-default .hg-button.hg-button-com{max-width:85px}.hg-theme-default .hg-button.hg-standardBtn.hg-button-at{max-width:45px}.hg-theme-default .hg-button.hg-selectedButton{background:rgba(5,25,70,.53);color:#fff}.hg-theme-default .hg-button.hg-standardBtn[data-skbtn=\".com\"]{max-width:82px}.hg-theme-default .hg-button.hg-standardBtn[data-skbtn=\"@\"]{max-width:60px}\n/*# sourceMappingURL=index.css.map */\n","/*!\n * \n * simple-keyboard v2.28.2\n * https://github.com/hodgef/simple-keyboard\n * \n * Copyright (c) Francisco Hodge (https://github.com/hodgef)\n * \n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n * \n */\n/**\n * simple-keyboard\n * Theme: hg-theme-default\n */\n.hg-theme-default {\n width: 100%;\n -webkit-user-select: none;\n -moz-user-select: none;\n -ms-user-select: none;\n user-select: none;\n box-sizing: border-box;\n overflow: hidden;\n touch-action: manipulation;\n}\n\n.hg-theme-default .hg-button span {\n pointer-events: none;\n}\n\n/* When using option \"useButtonTag\" */\n.hg-theme-default button.hg-button {\n border-width: 0;\n outline: 0;\n font-size: inherit;\n}\n\n.hg-theme-default {\n font-family: \"HelveticaNeue-Light\", \"Helvetica Neue Light\", \"Helvetica Neue\",\n Helvetica, Arial, \"Lucida Grande\", sans-serif;\n background-color: rgba(0, 0, 0, 0.1);\n padding: 5px;\n border-radius: 5px;\n}\n\n.hg-theme-default .hg-button {\n display: inline-block;\n flex-grow: 1;\n cursor: pointer;\n}\n\n.hg-theme-default .hg-row {\n display: flex;\n}\n\n.hg-theme-default .hg-row:not(:last-child) {\n margin-bottom: 5px;\n}\n\n.hg-theme-default .hg-row .hg-button:not(:last-child) {\n margin-right: 5px;\n}\n\n.hg-theme-default .hg-row .hg-button-container {\n margin-right: 5px;\n}\n\n.hg-theme-default .hg-row > div:last-child {\n margin-right: 0;\n}\n\n.hg-theme-default .hg-row .hg-button-container {\n display: flex;\n}\n\n.hg-theme-default .hg-button {\n box-shadow: 0px 0px 3px -1px rgba(0, 0, 0, 0.3);\n height: 40px;\n border-radius: 5px;\n box-sizing: border-box;\n padding: 5px;\n background: white;\n border-bottom: 1px solid #b5b5b5;\n cursor: pointer;\n display: flex;\n align-items: center;\n justify-content: center;\n -webkit-tap-highlight-color: rgba(0, 0, 0, 0);\n}\n\n.hg-theme-default .hg-button.hg-activeButton {\n background: #efefef;\n}\n\n.hg-theme-default.hg-layout-numeric .hg-button {\n width: 33.3%;\n height: 60px;\n align-items: center;\n display: flex;\n justify-content: center;\n}\n\n.hg-theme-default .hg-button.hg-button-numpadadd {\n height: 85px;\n}\n\n.hg-theme-default .hg-button.hg-button-numpadenter {\n height: 85px;\n}\n\n.hg-theme-default .hg-button.hg-button-numpad0 {\n width: 105px;\n}\n\n.hg-theme-default .hg-button.hg-button-com {\n max-width: 85px;\n}\n\n.hg-theme-default .hg-button.hg-standardBtn.hg-button-at {\n max-width: 45px;\n}\n\n.hg-theme-default .hg-button.hg-selectedButton {\n background: rgba(5, 25, 70, 0.53);\n color: white;\n}\n\n.hg-theme-default .hg-button.hg-standardBtn[data-skbtn=\".com\"] {\n max-width: 82px;\n}\n\n.hg-theme-default .hg-button.hg-standardBtn[data-skbtn=\"@\"] {\n max-width: 60px;\n}\n\n","/**\n * simple-keyboard\n * Theme: hg-theme-default\n */\n.hg-theme-default {\n width: 100%;\n user-select: none;\n box-sizing: border-box;\n overflow: hidden;\n touch-action: manipulation;\n}\n\n.hg-theme-default .hg-button span {\n pointer-events: none;\n}\n\n/* When using option \"useButtonTag\" */\n.hg-theme-default button.hg-button {\n border-width: 0;\n outline: 0;\n font-size: inherit;\n}\n\n.hg-theme-default {\n font-family: \"HelveticaNeue-Light\", \"Helvetica Neue Light\", \"Helvetica Neue\",\n Helvetica, Arial, \"Lucida Grande\", sans-serif;\n background-color: rgba(0, 0, 0, 0.1);\n padding: 5px;\n border-radius: 5px;\n}\n\n.hg-theme-default .hg-button {\n display: inline-block;\n flex-grow: 1;\n cursor: pointer;\n}\n\n.hg-theme-default .hg-row {\n display: flex;\n}\n\n.hg-theme-default .hg-row:not(:last-child) {\n margin-bottom: 5px;\n}\n\n.hg-theme-default .hg-row .hg-button:not(:last-child) {\n margin-right: 5px;\n}\n\n.hg-theme-default .hg-row .hg-button-container {\n margin-right: 5px;\n}\n\n.hg-theme-default .hg-row > div:last-child {\n margin-right: 0;\n}\n\n.hg-theme-default .hg-row .hg-button-container {\n display: flex;\n}\n\n.hg-theme-default .hg-button {\n box-shadow: 0px 0px 3px -1px rgba(0, 0, 0, 0.3);\n height: 40px;\n border-radius: 5px;\n box-sizing: border-box;\n padding: 5px;\n background: white;\n border-bottom: 1px solid #b5b5b5;\n cursor: pointer;\n display: flex;\n align-items: center;\n justify-content: center;\n -webkit-tap-highlight-color: rgba(0, 0, 0, 0);\n}\n\n.hg-theme-default .hg-button.hg-activeButton {\n background: #efefef;\n}\n\n.hg-theme-default.hg-layout-numeric .hg-button {\n width: 33.3%;\n height: 60px;\n align-items: center;\n display: flex;\n justify-content: center;\n}\n\n.hg-theme-default .hg-button.hg-button-numpadadd {\n height: 85px;\n}\n\n.hg-theme-default .hg-button.hg-button-numpadenter {\n height: 85px;\n}\n\n.hg-theme-default .hg-button.hg-button-numpad0 {\n width: 105px;\n}\n\n.hg-theme-default .hg-button.hg-button-com {\n max-width: 85px;\n}\n\n.hg-theme-default .hg-button.hg-standardBtn.hg-button-at {\n max-width: 45px;\n}\n\n.hg-theme-default .hg-button.hg-selectedButton {\n background: rgba(5, 25, 70, 0.53);\n color: white;\n}\n\n.hg-theme-default .hg-button.hg-standardBtn[data-skbtn=\".com\"] {\n max-width: 82px;\n}\n\n.hg-theme-default .hg-button.hg-standardBtn[data-skbtn=\"@\"] {\n max-width: 60px;\n}\n"]} \ No newline at end of file diff --git a/build/index.js b/build/index.js index 72a7d217a..475957c16 100644 --- a/build/index.js +++ b/build/index.js @@ -1,6 +1,6 @@ /*! * - * react-simple-keyboard v2.1.117 + * react-simple-keyboard v2.2.0 * https://github.com/hodgef/react-simple-keyboard * * Copyright (c) Francisco Hodge (https://github.com/hodgef) @@ -9,5 +9,5 @@ * LICENSE file in the root directory of this source tree. * */ -!function(t,e){"object"===typeof exports&&"object"===typeof module?module.exports=e(require("react")):"function"===typeof define&&define.amd?define("ReactSimpleKeyboard",["react"],e):"object"===typeof exports?exports.ReactSimpleKeyboard=e(require("react")):t.ReactSimpleKeyboard=e(t.React)}(window,(function(t){return function(t){var e={};function __webpack_require__(n){if(e[n])return e[n].exports;var o=e[n]={i:n,l:!1,exports:{}};return t[n].call(o.exports,o,o.exports,__webpack_require__),o.l=!0,o.exports}return __webpack_require__.m=t,__webpack_require__.c=e,__webpack_require__.d=function(t,e,n){__webpack_require__.o(t,e)||Object.defineProperty(t,e,{enumerable:!0,get:n})},__webpack_require__.r=function(t){"undefined"!==typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},__webpack_require__.t=function(t,e){if(1&e&&(t=__webpack_require__(t)),8&e)return t;if(4&e&&"object"===typeof t&&t&&t.__esModule)return t;var n=Object.create(null);if(__webpack_require__.r(n),Object.defineProperty(n,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var o in t)__webpack_require__.d(n,o,function(e){return t[e]}.bind(null,o));return n},__webpack_require__.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return __webpack_require__.d(e,"a",e),e},__webpack_require__.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},__webpack_require__.p="",__webpack_require__(__webpack_require__.s=2)}([function(e,n){e.exports=t},function(t,e,n){(function(t){var o,i,s,r,a=n(4);window,r=function(){return function(t){var e={};function __webpack_require__(n){if(e[n])return e[n].exports;var o=e[n]={i:n,l:!1,exports:{}};return t[n].call(o.exports,o,o.exports,__webpack_require__),o.l=!0,o.exports}return __webpack_require__.m=t,__webpack_require__.c=e,__webpack_require__.d=function(t,e,n){__webpack_require__.o(t,e)||Object.defineProperty(t,e,{enumerable:!0,get:n})},__webpack_require__.r=function(t){"undefined"!==typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},__webpack_require__.t=function(t,e){if(1&e&&(t=__webpack_require__(t)),8&e)return t;if(4&e&&"object"===a(t)&&t&&t.__esModule)return t;var n=Object.create(null);if(__webpack_require__.r(n),Object.defineProperty(n,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var o in t)__webpack_require__.d(n,o,function(e){return t[e]}.bind(null,o));return n},__webpack_require__.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return __webpack_require__.d(e,"a",e),e},__webpack_require__.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},__webpack_require__.p="",__webpack_require__(__webpack_require__.s=0)}([function(t,e,n){t.exports=n(2)},function(t,e,n){},function(t,e,n){"use strict";function _typeof(t){return(_typeof="function"===typeof Symbol&&"symbol"===a(Symbol.iterator)?function(t){return a(t)}:function(t){return t&&"function"===typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":a(t)})(t)}function _defineProperties(t,e){for(var n=0;n0?s=this.removeAt(s,n,o):"{space}"===t?s=this.addStringAt(s," ",n,o):"{tab}"!==t||"boolean"===typeof i.tabCharOnTab&&!1===i.tabCharOnTab?"{enter}"!==t&&"{numpadenter}"!==t||!i.newLineOnEnter?t.includes("numpad")&&Number.isInteger(Number(t[t.length-2]))?s=this.addStringAt(s,t[t.length-2],n,o):"{numpaddivide}"===t?s=this.addStringAt(s,"/",n,o):"{numpadmultiply}"===t?s=this.addStringAt(s,"*",n,o):"{numpadsubtract}"===t?s=this.addStringAt(s,"-",n,o):"{numpadadd}"===t?s=this.addStringAt(s,"+",n,o):"{numpaddecimal}"===t?s=this.addStringAt(s,".",n,o):"{"===t||"}"===t?s=this.addStringAt(s,t,n,o):t.includes("{")||t.includes("}")||(s=this.addStringAt(s,t,n,o)):s=this.addStringAt(s,"\n",n,o):s=this.addStringAt(s,"\t",n,o),s}},{key:"updateCaretPos",value:function(t,e){var n=this.updateCaretPosAction(t,e);this.dispatch((function(t){t.caretPosition=n}))}},{key:"updateCaretPosAction",value:function(t,e){var n=this.getOptions(),o=this.getCaretPosition();return e?o>0&&(o-=t):o+=t,n.debug&&console.log("Caret at:",o,"(".concat(this.keyboardDOMClass,")")),o}},{key:"addStringAt",value:function(t,e,n,o){var i;return n||0===n?(i=[t.slice(0,n),e,t.slice(n)].join(""),this.isMaxLengthReached()||o&&this.updateCaretPos(e.length)):i=t+e,i}},{key:"removeAt",value:function(t,e,n){var o;if(0===this.getCaretPosition())return t;var i=/([\uD800-\uDBFF][\uDC00-\uDFFF])/g;return e&&e>=0?t.substring(e-2,e).match(i)?(o=t.substr(0,e-2)+t.substr(e),n&&this.updateCaretPos(2,!0)):(o=t.substr(0,e-1)+t.substr(e),n&&this.updateCaretPos(1,!0)):t.slice(-2).match(i)?(o=t.slice(0,-2),n&&this.updateCaretPos(2,!0)):(o=t.slice(0,-1),n&&this.updateCaretPos(1,!0)),o}},{key:"handleMaxLength",value:function(t,e){var n=this.getOptions(),o=n.maxLength,i=t[n.inputName],s=e.length-1>=o;if(e.length<=i.length)return!1;if(Number.isInteger(o))return n.debug&&console.log("maxLength (num) reached:",s),s?(this.maxLengthReached=!0,!0):(this.maxLengthReached=!1,!1);if("object"===_typeof(o)){var r=i.length===o[n.inputName];return n.debug&&console.log("maxLength (obj) reached:",r),r?(this.maxLengthReached=!0,!0):(this.maxLengthReached=!1,!1)}}},{key:"isMaxLengthReached",value:function(){return Boolean(this.maxLengthReached)}},{key:"isTouchDevice",value:function(){return"ontouchstart"in window||navigator.maxTouchPoints}},{key:"pointerEventsSupported",value:function(){return window.PointerEvent}},{key:"camelCase",value:function(t){return!!t&&t.toLowerCase().trim().split(/[.\-_\s]/g).reduce((function(t,e){return e.length?t+e[0].toUpperCase()+e.slice(1):t}))}}])&&_defineProperties(t.prototype,e),n&&_defineProperties(t,n),Utilities}();function PhysicalKeyboard_defineProperties(t,e){for(var n=0;n ? {shift}",".com @ {space}"]}}}])&&KeyboardLayout_defineProperties(t,e),KeyboardLayout}();function _toConsumableArray(t){return function(t){if(Array.isArray(t)){for(var e=0,n=new Array(t.length);e1?n:n[0]),e}},{key:"inputPatternIsValid",value:function(t){var e,n=this.options.inputPattern;if((e=n instanceof RegExp?n:n[this.options.inputName])&&t){var o=e.test(t);return this.options.debug&&console.log('inputPattern ("'.concat(e,'"): ').concat(o?"passed":"did not pass!")),o}return!0}},{key:"setEventListeners",value:function(){!this.isFirstKeyboardInstance&&this.allKeyboardInstances||(this.options.debug&&console.log("Caret handling started (".concat(this.keyboardDOMClass,")")),document.addEventListener("keyup",this.handleKeyUp),document.addEventListener("keydown",this.handleKeyDown),document.addEventListener("mouseup",this.handleMouseUp),document.addEventListener("touchend",this.handleTouchEnd))}},{key:"handleKeyUp",value:function(t){this.caretEventHandler(t),this.options.physicalKeyboardHighlight&&this.physicalKeyboard.handleHighlightKeyUp(t)}},{key:"handleKeyDown",value:function(t){this.options.physicalKeyboardHighlight&&this.physicalKeyboard.handleHighlightKeyDown(t)}},{key:"handleMouseUp",value:function(t){this.caretEventHandler(t)}},{key:"handleTouchEnd",value:function(t){this.caretEventHandler(t)}},{key:"caretEventHandler",value:function(t){var e;t.target.tagName&&(e=t.target.tagName.toLowerCase()),this.dispatch((function(n){n.isMouseHold&&(n.isMouseHold=!1),"textarea"!==e&&"input"!==e||n.options.disableCaretPositioning?n.options.disableCaretPositioning&&(n.caretPosition=null):(n.caretPosition=t.target.selectionStart,n.options.debug&&console.log("Caret at: ",t.target.selectionStart,t.target.tagName.toLowerCase(),"(".concat(n.keyboardDOMClass,")")))}))}},{key:"recurseButtons",value:function(t){var e=this;if(!t)return!1;Object.keys(this.buttonElements).forEach((function(n){return e.buttonElements[n].forEach(t)}))}},{key:"destroy",value:function(){this.options.debug&&console.log("Destroying simple-keyboard instance: ".concat(this.currentInstanceName)),document.removeEventListener("keyup",this.handleKeyUp),document.removeEventListener("keydown",this.handleKeyDown),document.removeEventListener("mouseup",this.handleMouseUp),document.removeEventListener("touchend",this.handleTouchEnd),document.onpointerup=null,document.ontouchend=null,document.ontouchcancel=null,document.onmouseup=null;var deleteButton=function(t){t.onpointerdown=null,t.onpointerup=null,t.onpointercancel=null,t.ontouchstart=null,t.ontouchend=null,t.ontouchcancel=null,t.onclick=null,t.onmousedown=null,t.onmouseup=null,t.remove(),t=null};this.recurseButtons(deleteButton),this.recurseButtons=null,deleteButton=null,this.keyboardDOM.onpointerdown=null,this.keyboardDOM.ontouchstart=null,this.keyboardDOM.onmousedown=null,this.clear(),window.SimpleKeyboardInstances[this.currentInstanceName]=null,delete window.SimpleKeyboardInstances[this.currentInstanceName],this.initialized=!1}},{key:"getButtonThemeClasses",value:function(t){var e=this.options.buttonTheme,n=[];return Array.isArray(e)&&e.forEach((function(e){if(e.class&&"string"===typeof e.class&&e.buttons&&"string"===typeof e.buttons){var o=e.class.split(" ");e.buttons.split(" ").includes(t)&&(n=[].concat(_toConsumableArray(n),_toConsumableArray(o)))}else console.warn('Incorrect "buttonTheme". Please check the documentation.',e)})),n}},{key:"setDOMButtonAttributes",value:function(t,e){var n=this.options.buttonAttributes;Array.isArray(n)&&n.forEach((function(n){n.attribute&&"string"===typeof n.attribute&&n.value&&"string"===typeof n.value&&n.buttons&&"string"===typeof n.buttons?n.buttons.split(" ").includes(t)&&e(n.attribute,n.value):console.warn('Incorrect "buttonAttributes". Please check the documentation.',n)}))}},{key:"onTouchDeviceDetected",value:function(){this.processAutoTouchEvents(),this.disableContextualWindow()}},{key:"disableContextualWindow",value:function(){window.oncontextmenu=function(t){if(t.target.classList.contains("hg-button"))return t.preventDefault(),t.stopPropagation(),!1}}},{key:"processAutoTouchEvents",value:function(){this.options.autoUseTouchEvents&&(this.options.useTouchEvents=!0,this.options.debug&&console.log("autoUseTouchEvents: Touch device detected, useTouchEvents enabled."))}},{key:"onInit",value:function(){this.options.debug&&console.log("".concat(this.keyboardDOMClass," Initialized")),this.setEventListeners(),"function"===typeof this.options.onInit&&this.options.onInit()}},{key:"beforeFirstRender",value:function(){this.utilities.isTouchDevice()&&this.onTouchDeviceDetected(),"function"===typeof this.options.beforeFirstRender&&this.options.beforeFirstRender(),this.isFirstKeyboardInstance&&this.utilities.pointerEventsSupported()&&!this.options.useTouchEvents&&!this.options.useMouseEvents&&this.options.debug&&console.log("Using PointerEvents as it is supported by this browser"),this.options.useTouchEvents&&this.options.debug&&console.log("useTouchEvents has been enabled. Only touch events will be used.")}},{key:"beforeRender",value:function(){"function"===typeof this.options.beforeRender&&this.options.beforeRender()}},{key:"onRender",value:function(){"function"===typeof this.options.onRender&&this.options.onRender()}},{key:"onModulesLoaded",value:function(){"function"===typeof this.options.onModulesLoaded&&this.options.onModulesLoaded()}},{key:"loadModules",value:function(){var t=this;Array.isArray(this.options.modules)&&(this.options.modules.forEach((function(e){var n=new e;if(n.constructor.name&&"Function"!==n.constructor.name){var o="module-".concat(t.utilities.camelCase(n.constructor.name));t.keyboardPluginClasses=t.keyboardPluginClasses+" ".concat(o)}n.init(t)})),this.keyboardPluginClasses=this.keyboardPluginClasses+" modules-loaded",this.render(),this.onModulesLoaded())}},{key:"getModuleProp",value:function(t,e){return!!this.modules[t]&&this.modules[t][e]}},{key:"getModulesList",value:function(){return Object.keys(this.modules)}},{key:"parseRowDOMContainers",value:function(t,e,n,o){var i=this,s=Array.from(t.children),r=0;return s.length&&n.forEach((function(n,a){var u=o[a];if(!u||!(u>n))return!1;var c=n-r,l=u-r,d=document.createElement("div");d.className+="hg-button-container";var p="".concat(i.options.layoutName,"-r").concat(e,"c").concat(a);d.setAttribute("data-skUID",p);var h=s.splice(c,l-c+1);r=l-c,h.forEach((function(t){return d.appendChild(t)})),s.splice(c,0,d),t.innerHTML="",s.forEach((function(e){return t.appendChild(e)})),i.options.debug&&console.log("rowDOMContainer",h,c,l,r+1)})),t}},{key:"render",value:function(){var t=this;this.clear(),this.initialized||this.beforeFirstRender(),this.beforeRender();var e="hg-layout-".concat(this.options.layoutName),n=this.options.layout||s.getDefaultLayout(),o=this.options.useTouchEvents||!1,i=o?"hg-touch-events":"",r=this.options.useMouseEvents||!1,a=this.options.disableRowButtonContainers;this.keyboardDOM.className+=" ".concat(this.options.theme," ").concat(e," ").concat(this.keyboardPluginClasses," ").concat(i),n[this.options.layoutName].forEach((function(e,n){var i=e.split(" "),s=document.createElement("div");s.className+="hg-row";var u=[],c=[];i.forEach((function(e,i){var l,d=!a&&e.includes("[")&&e.length>1,p=!a&&e.includes("]")&&e.length>1;d&&(u.push(i),e=e.replace(/\[/g,"")),p&&(c.push(i),e=e.replace(/\]/g,""));var h=t.utilities.getButtonClass(e),f=t.utilities.getButtonDisplayName(e,t.options.display,t.options.mergeDisplay),y=t.options.useButtonTag?"button":"div",b=document.createElement(y);b.className+="hg-button ".concat(h),(l=b.classList).add.apply(l,_toConsumableArray(t.getButtonThemeClasses(e))),t.setDOMButtonAttributes(e,(function(t,e){b.setAttribute(t,e)})),t.activeButtonClass="hg-activeButton",!t.utilities.pointerEventsSupported()||o||r?o?(b.ontouchstart=function(n){t.handleButtonClicked(e),t.handleButtonMouseDown(e,n)},b.ontouchend=function(){t.handleButtonMouseUp(e)},b.ontouchcancel=function(){t.handleButtonMouseUp(e)}):(b.onclick=function(){t.isMouseHold=!1,t.handleButtonClicked(e)},b.onmousedown=function(n){t.handleButtonMouseDown(e,n)},b.onmouseup=function(){t.handleButtonMouseUp(e)}):(b.onpointerdown=function(n){t.handleButtonClicked(e),t.handleButtonMouseDown(e,n)},b.onpointerup=function(){t.handleButtonMouseUp(e)},b.onpointercancel=function(){t.handleButtonMouseUp(e)}),b.setAttribute("data-skBtn",e);var m="".concat(t.options.layoutName,"-r").concat(n,"b").concat(i);b.setAttribute("data-skBtnUID",m);var g=document.createElement("span");g.innerHTML=f,b.appendChild(g),t.buttonElements[e]||(t.buttonElements[e]=[]),t.buttonElements[e].push(b),s.appendChild(b)})),s=t.parseRowDOMContainers(s,n,u,c),t.keyboardDOM.appendChild(s)})),this.onRender(),this.initialized||(this.initialized=!0,!this.utilities.pointerEventsSupported()||o||r?o?(document.ontouchend=function(){return t.handleButtonMouseUp()},document.ontouchcancel=function(){return t.handleButtonMouseUp()},this.keyboardDOM.ontouchstart=function(e){return t.handleKeyboardContainerMouseDown(e)}):o||(document.onmouseup=function(){return t.handleButtonMouseUp()},this.keyboardDOM.onmousedown=function(e){return t.handleKeyboardContainerMouseDown(e)}):(document.onpointerup=function(){return t.handleButtonMouseUp()},this.keyboardDOM.onpointerdown=function(e){return t.handleKeyboardContainerMouseDown(e)}),this.onInit())}}])&&Keyboard_defineProperties(t.prototype,e),SimpleKeyboard}();e.default=r}])},"object"===a(e)&&"object"===a(t)?t.exports=r():(i=[],void 0===(s="function"===typeof(o=r)?o.apply(e,i):o)||(t.exports=s))}).call(this,n(3)(t))},function(t,e,n){t.exports=n(6)},function(t,e){t.exports=function(t){return t.webpackPolyfill||(t.deprecate=function(){},t.paths=[],t.children||(t.children=[]),Object.defineProperty(t,"loaded",{enumerable:!0,get:function(){return t.l}}),Object.defineProperty(t,"id",{enumerable:!0,get:function(){return t.i}}),t.webpackPolyfill=1),t}},function(t,e){function _typeof(e){return"function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?t.exports=_typeof=function(t){return typeof t}:t.exports=_typeof=function(t){return t&&"function"===typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},_typeof(e)}t.exports=_typeof},function(t,e,n){},function(t,e,n){"use strict";n.r(e);var o=n(0),i=n.n(o),s=n(1),r=n.n(s);function ownKeys(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(t);e&&(o=o.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),n.push.apply(n,o)}return n}function _objectSpread(t){for(var e=1;e0?s=this.removeAt(s,n,o):"{space}"===e?s=this.addStringAt(s," ",n,o):"{tab}"!==e||"boolean"===typeof i.tabCharOnTab&&!1===i.tabCharOnTab?"{enter}"!==e&&"{numpadenter}"!==e||!i.newLineOnEnter?e.includes("numpad")&&Number.isInteger(Number(e[e.length-2]))?s=this.addStringAt(s,e[e.length-2],n,o):"{numpaddivide}"===e?s=this.addStringAt(s,"/",n,o):"{numpadmultiply}"===e?s=this.addStringAt(s,"*",n,o):"{numpadsubtract}"===e?s=this.addStringAt(s,"-",n,o):"{numpadadd}"===e?s=this.addStringAt(s,"+",n,o):"{numpaddecimal}"===e?s=this.addStringAt(s,".",n,o):"{"===e||"}"===e?s=this.addStringAt(s,e,n,o):e.includes("{")||e.includes("}")||(s=this.addStringAt(s,e,n,o)):s=this.addStringAt(s,"\n",n,o):s=this.addStringAt(s,"\t",n,o),s}},{key:"updateCaretPos",value:function(e,t){var n=this.updateCaretPosAction(e,t);this.dispatch((function(e){e.caretPosition=n}))}},{key:"updateCaretPosAction",value:function(e,t){var n=this.getOptions(),o=this.getCaretPosition();return t?o>0&&(o-=e):o+=e,n.debug&&console.log("Caret at:",o,"(".concat(this.keyboardDOMClass,")")),o}},{key:"addStringAt",value:function(e,t,n,o){var i;return n||0===n?(i=[e.slice(0,n),t,e.slice(n)].join(""),this.isMaxLengthReached()||o&&this.updateCaretPos(t.length)):i=e+t,i}},{key:"removeAt",value:function(e,t,n){var o;if(0===this.getCaretPosition())return e;var i=/([\uD800-\uDBFF][\uDC00-\uDFFF])/g;return t&&t>=0?e.substring(t-2,t).match(i)?(o=e.substr(0,t-2)+e.substr(t),n&&this.updateCaretPos(2,!0)):(o=e.substr(0,t-1)+e.substr(t),n&&this.updateCaretPos(1,!0)):e.slice(-2).match(i)?(o=e.slice(0,-2),n&&this.updateCaretPos(2,!0)):(o=e.slice(0,-1),n&&this.updateCaretPos(1,!0)),o}},{key:"handleMaxLength",value:function(e,t){var n=this.getOptions(),o=n.maxLength,i=e[n.inputName],s=t.length-1>=o;if(t.length<=i.length)return!1;if(Number.isInteger(o))return n.debug&&console.log("maxLength (num) reached:",s),s?(this.maxLengthReached=!0,!0):(this.maxLengthReached=!1,!1);if("object"===_typeof(o)){var r=i.length===o[n.inputName];return n.debug&&console.log("maxLength (obj) reached:",r),r?(this.maxLengthReached=!0,!0):(this.maxLengthReached=!1,!1)}}},{key:"isMaxLengthReached",value:function(){return Boolean(this.maxLengthReached)}},{key:"isTouchDevice",value:function(){return"ontouchstart"in window||navigator.maxTouchPoints}},{key:"pointerEventsSupported",value:function(){return window.PointerEvent}},{key:"camelCase",value:function(e){return!!e&&e.toLowerCase().trim().split(/[.\-_\s]/g).reduce((function(e,t){return t.length?e+t[0].toUpperCase()+t.slice(1):e}))}}])&&_defineProperties(e.prototype,t),n&&_defineProperties(e,n),Utilities}();function PhysicalKeyboard_defineProperties(e,t){for(var n=0;n1?n:n[0]),t}},{key:"inputPatternIsValid",value:function(e){var t,n=this.options.inputPattern;if((t=n instanceof RegExp?n:n[this.options.inputName])&&e){var o=t.test(e);return this.options.debug&&console.log('inputPattern ("'.concat(t,'"): ').concat(o?"passed":"did not pass!")),o}return!0}},{key:"setEventListeners",value:function(){!this.isFirstKeyboardInstance&&this.allKeyboardInstances||(this.options.debug&&console.log("Caret handling started (".concat(this.keyboardDOMClass,")")),document.addEventListener("keyup",this.handleKeyUp),document.addEventListener("keydown",this.handleKeyDown),document.addEventListener("mouseup",this.handleMouseUp),document.addEventListener("touchend",this.handleTouchEnd))}},{key:"handleKeyUp",value:function(e){this.caretEventHandler(e),this.options.physicalKeyboardHighlight&&this.physicalKeyboard.handleHighlightKeyUp(e)}},{key:"handleKeyDown",value:function(e){this.options.physicalKeyboardHighlight&&this.physicalKeyboard.handleHighlightKeyDown(e)}},{key:"handleMouseUp",value:function(e){this.caretEventHandler(e)}},{key:"handleTouchEnd",value:function(e){this.caretEventHandler(e)}},{key:"caretEventHandler",value:function(e){var t;e.target.tagName&&(t=e.target.tagName.toLowerCase()),this.dispatch((function(n){n.isMouseHold&&(n.isMouseHold=!1),"textarea"!==t&&"input"!==t||n.options.disableCaretPositioning?n.options.disableCaretPositioning&&(n.caretPosition=null):(n.caretPosition=e.target.selectionStart,n.options.debug&&console.log("Caret at: ",e.target.selectionStart,e.target.tagName.toLowerCase(),"(".concat(n.keyboardDOMClass,")")))}))}},{key:"recurseButtons",value:function(e){var t=this;if(!e)return!1;Object.keys(this.buttonElements).forEach((function(n){return t.buttonElements[n].forEach(e)}))}},{key:"destroy",value:function(){this.options.debug&&console.log("Destroying simple-keyboard instance: ".concat(this.currentInstanceName)),document.removeEventListener("keyup",this.handleKeyUp),document.removeEventListener("keydown",this.handleKeyDown),document.removeEventListener("mouseup",this.handleMouseUp),document.removeEventListener("touchend",this.handleTouchEnd),document.onpointerup=null,document.ontouchend=null,document.ontouchcancel=null,document.onmouseup=null;var deleteButton=function(e){e.onpointerdown=null,e.onpointerup=null,e.onpointercancel=null,e.ontouchstart=null,e.ontouchend=null,e.ontouchcancel=null,e.onclick=null,e.onmousedown=null,e.onmouseup=null,e.remove(),e=null};this.recurseButtons(deleteButton),this.recurseButtons=null,deleteButton=null,this.keyboardDOM.onpointerdown=null,this.keyboardDOM.ontouchstart=null,this.keyboardDOM.onmousedown=null,this.clear(),window.SimpleKeyboardInstances[this.currentInstanceName]=null,delete window.SimpleKeyboardInstances[this.currentInstanceName],this.initialized=!1}},{key:"getButtonThemeClasses",value:function(e){var t=this.options.buttonTheme,n=[];return Array.isArray(t)&&t.forEach((function(t){if(t.class&&"string"===typeof t.class&&t.buttons&&"string"===typeof t.buttons){var o=t.class.split(" ");t.buttons.split(" ").includes(e)&&(n=[].concat(_toConsumableArray(n),_toConsumableArray(o)))}else console.warn('Incorrect "buttonTheme". Please check the documentation.',t)})),n}},{key:"setDOMButtonAttributes",value:function(e,t){var n=this.options.buttonAttributes;Array.isArray(n)&&n.forEach((function(n){n.attribute&&"string"===typeof n.attribute&&n.value&&"string"===typeof n.value&&n.buttons&&"string"===typeof n.buttons?n.buttons.split(" ").includes(e)&&t(n.attribute,n.value):console.warn('Incorrect "buttonAttributes". Please check the documentation.',n)}))}},{key:"onTouchDeviceDetected",value:function(){this.processAutoTouchEvents(),this.disableContextualWindow()}},{key:"disableContextualWindow",value:function(){window.oncontextmenu=function(e){if(e.target.classList.contains("hg-button"))return e.preventDefault(),e.stopPropagation(),!1}}},{key:"processAutoTouchEvents",value:function(){this.options.autoUseTouchEvents&&(this.options.useTouchEvents=!0,this.options.debug&&console.log("autoUseTouchEvents: Touch device detected, useTouchEvents enabled."))}},{key:"onInit",value:function(){this.options.debug&&console.log("".concat(this.keyboardDOMClass," Initialized")),this.setEventListeners(),"function"===typeof this.options.onInit&&this.options.onInit()}},{key:"beforeFirstRender",value:function(){this.utilities.isTouchDevice()&&this.onTouchDeviceDetected(),"function"===typeof this.options.beforeFirstRender&&this.options.beforeFirstRender(),this.isFirstKeyboardInstance&&this.utilities.pointerEventsSupported()&&!this.options.useTouchEvents&&!this.options.useMouseEvents&&this.options.debug&&console.log("Using PointerEvents as it is supported by this browser"),this.options.useTouchEvents&&this.options.debug&&console.log("useTouchEvents has been enabled. Only touch events will be used.")}},{key:"beforeRender",value:function(){"function"===typeof this.options.beforeRender&&this.options.beforeRender()}},{key:"onRender",value:function(){"function"===typeof this.options.onRender&&this.options.onRender()}},{key:"onModulesLoaded",value:function(){"function"===typeof this.options.onModulesLoaded&&this.options.onModulesLoaded()}},{key:"loadModules",value:function(){var e=this;Array.isArray(this.options.modules)&&(this.options.modules.forEach((function(t){var n=new t;if(n.constructor.name&&"Function"!==n.constructor.name){var o="module-".concat(e.utilities.camelCase(n.constructor.name));e.keyboardPluginClasses=e.keyboardPluginClasses+" ".concat(o)}n.init(e)})),this.keyboardPluginClasses=this.keyboardPluginClasses+" modules-loaded",this.render(),this.onModulesLoaded())}},{key:"getModuleProp",value:function(e,t){return!!this.modules[e]&&this.modules[e][t]}},{key:"getModulesList",value:function(){return Object.keys(this.modules)}},{key:"parseRowDOMContainers",value:function(e,t,n,o){var i=this,s=Array.from(e.children),r=0;return s.length&&n.forEach((function(n,a){var u=o[a];if(!u||!(u>n))return!1;var c=n-r,l=u-r,d=document.createElement("div");d.className+="hg-button-container";var p="".concat(i.options.layoutName,"-r").concat(t,"c").concat(a);d.setAttribute("data-skUID",p);var h=s.splice(c,l-c+1);r=l-c,h.forEach((function(e){return d.appendChild(e)})),s.splice(c,0,d),e.innerHTML="",s.forEach((function(t){return e.appendChild(t)})),i.options.debug&&console.log("rowDOMContainer",h,c,l,r+1)})),e}},{key:"render",value:function(){var e=this;this.clear(),this.initialized||this.beforeFirstRender(),this.beforeRender();var t="hg-layout-".concat(this.options.layoutName),n=this.options.layout||{default:["` 1 2 3 4 5 6 7 8 9 0 - = {bksp}","{tab} q w e r t y u i o p [ ] \\","{lock} a s d f g h j k l ; ' {enter}","{shift} z x c v b n m , . / {shift}",".com @ {space}"],shift:["~ ! @ # $ % ^ & * ( ) _ + {bksp}","{tab} Q W E R T Y U I O P { } |",'{lock} A S D F G H J K L : " {enter}',"{shift} Z X C V B N M < > ? {shift}",".com @ {space}"]},o=this.options.useTouchEvents||!1,i=o?"hg-touch-events":"",s=this.options.useMouseEvents||!1,r=this.options.disableRowButtonContainers;this.keyboardDOM.className=this.getKeyboardClassString(this.options.theme,t,this.keyboardPluginClasses,i),n[this.options.layoutName].forEach((function(t,n){var i=t.split(" "),a=document.createElement("div");a.className+="hg-row";var u=[],c=[];i.forEach((function(t,i){var l,d=!r&&t.includes("[")&&t.length>1,p=!r&&t.includes("]")&&t.length>1;d&&(u.push(i),t=t.replace(/\[/g,"")),p&&(c.push(i),t=t.replace(/\]/g,""));var h=e.utilities.getButtonClass(t),f=e.utilities.getButtonDisplayName(t,e.options.display,e.options.mergeDisplay),y=e.options.useButtonTag?"button":"div",b=document.createElement(y);b.className+="hg-button ".concat(h),(l=b.classList).add.apply(l,_toConsumableArray(e.getButtonThemeClasses(t))),e.setDOMButtonAttributes(t,(function(e,t){b.setAttribute(e,t)})),e.activeButtonClass="hg-activeButton",!e.utilities.pointerEventsSupported()||o||s?o?(b.ontouchstart=function(n){e.handleButtonClicked(t),e.handleButtonMouseDown(t,n)},b.ontouchend=function(){e.handleButtonMouseUp(t)},b.ontouchcancel=function(){e.handleButtonMouseUp(t)}):(b.onclick=function(){e.isMouseHold=!1,e.handleButtonClicked(t)},b.onmousedown=function(n){e.handleButtonMouseDown(t,n)},b.onmouseup=function(){e.handleButtonMouseUp(t)}):(b.onpointerdown=function(n){e.handleButtonClicked(t),e.handleButtonMouseDown(t,n)},b.onpointerup=function(){e.handleButtonMouseUp(t)},b.onpointercancel=function(){e.handleButtonMouseUp(t)}),b.setAttribute("data-skBtn",t);var m="".concat(e.options.layoutName,"-r").concat(n,"b").concat(i);b.setAttribute("data-skBtnUID",m);var g=document.createElement("span");g.innerHTML=f,b.appendChild(g),e.buttonElements[t]||(e.buttonElements[t]=[]),e.buttonElements[t].push(b),a.appendChild(b)})),a=e.parseRowDOMContainers(a,n,u,c),e.keyboardDOM.appendChild(a)})),this.onRender(),this.initialized||(this.initialized=!0,!this.utilities.pointerEventsSupported()||o||s?o?(document.ontouchend=function(){return e.handleButtonMouseUp()},document.ontouchcancel=function(){return e.handleButtonMouseUp()},this.keyboardDOM.ontouchstart=function(t){return e.handleKeyboardContainerMouseDown(t)}):o||(document.onmouseup=function(){return e.handleButtonMouseUp()},this.keyboardDOM.onmousedown=function(t){return e.handleKeyboardContainerMouseDown(t)}):(document.onpointerup=function(){return e.handleButtonMouseUp()},this.keyboardDOM.onpointerdown=function(t){return e.handleKeyboardContainerMouseDown(t)}),this.onInit())}}])&&Keyboard_defineProperties(e.prototype,t),SimpleKeyboard}();t.default=s}])},"object"===a(t)&&"object"===a(e)?e.exports=r():(i=[],void 0===(s="function"===typeof(o=r)?o.apply(t,i):o)||(e.exports=s))}).call(this,n(3)(e))},function(e,t,n){e.exports=n(6)},function(e,t){e.exports=function(e){return e.webpackPolyfill||(e.deprecate=function(){},e.paths=[],e.children||(e.children=[]),Object.defineProperty(e,"loaded",{enumerable:!0,get:function(){return e.l}}),Object.defineProperty(e,"id",{enumerable:!0,get:function(){return e.i}}),e.webpackPolyfill=1),e}},function(e,t){function _typeof(t){return"function"===typeof Symbol&&"symbol"===typeof Symbol.iterator?e.exports=_typeof=function(e){return typeof e}:e.exports=_typeof=function(e){return e&&"function"===typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},_typeof(t)}e.exports=_typeof},function(e,t,n){},function(e,t,n){"use strict";n.r(t);var o=n(0),i=n.n(o),s=n(1),r=n.n(s);function ownKeys(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);t&&(o=o.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,o)}return n}function _objectSpread(e){for(var t=1;t 0 ? s = this.removeAt(s, n, o) : \"{space}\" === t ? s = this.addStringAt(s, \" \", n, o) : \"{tab}\" !== t || \"boolean\" === typeof i.tabCharOnTab && !1 === i.tabCharOnTab ? \"{enter}\" !== t && \"{numpadenter}\" !== t || !i.newLineOnEnter ? t.includes(\"numpad\") && Number.isInteger(Number(t[t.length - 2])) ? s = this.addStringAt(s, t[t.length - 2], n, o) : \"{numpaddivide}\" === t ? s = this.addStringAt(s, \"/\", n, o) : \"{numpadmultiply}\" === t ? s = this.addStringAt(s, \"*\", n, o) : \"{numpadsubtract}\" === t ? s = this.addStringAt(s, \"-\", n, o) : \"{numpadadd}\" === t ? s = this.addStringAt(s, \"+\", n, o) : \"{numpaddecimal}\" === t ? s = this.addStringAt(s, \".\", n, o) : \"{\" === t || \"}\" === t ? s = this.addStringAt(s, t, n, o) : t.includes(\"{\") || t.includes(\"}\") || (s = this.addStringAt(s, t, n, o)) : s = this.addStringAt(s, \"\\n\", n, o) : s = this.addStringAt(s, \"\\t\", n, o), s;\n }\n }, {\n key: \"updateCaretPos\",\n value: function value(t, e) {\n var n = this.updateCaretPosAction(t, e);\n this.dispatch(function (t) {\n t.caretPosition = n;\n });\n }\n }, {\n key: \"updateCaretPosAction\",\n value: function value(t, e) {\n var n = this.getOptions(),\n o = this.getCaretPosition();\n return e ? o > 0 && (o -= t) : o += t, n.debug && console.log(\"Caret at:\", o, \"(\".concat(this.keyboardDOMClass, \")\")), o;\n }\n }, {\n key: \"addStringAt\",\n value: function value(t, e, n, o) {\n var i;\n return n || 0 === n ? (i = [t.slice(0, n), e, t.slice(n)].join(\"\"), this.isMaxLengthReached() || o && this.updateCaretPos(e.length)) : i = t + e, i;\n }\n }, {\n key: \"removeAt\",\n value: function value(t, e, n) {\n var o;\n if (0 === this.getCaretPosition()) return t;\n var i = /([\\uD800-\\uDBFF][\\uDC00-\\uDFFF])/g;\n return e && e >= 0 ? t.substring(e - 2, e).match(i) ? (o = t.substr(0, e - 2) + t.substr(e), n && this.updateCaretPos(2, !0)) : (o = t.substr(0, e - 1) + t.substr(e), n && this.updateCaretPos(1, !0)) : t.slice(-2).match(i) ? (o = t.slice(0, -2), n && this.updateCaretPos(2, !0)) : (o = t.slice(0, -1), n && this.updateCaretPos(1, !0)), o;\n }\n }, {\n key: \"handleMaxLength\",\n value: function value(t, e) {\n var n = this.getOptions(),\n o = n.maxLength,\n i = t[n.inputName],\n s = e.length - 1 >= o;\n if (e.length <= i.length) return !1;\n if (Number.isInteger(o)) return n.debug && console.log(\"maxLength (num) reached:\", s), s ? (this.maxLengthReached = !0, !0) : (this.maxLengthReached = !1, !1);\n\n if (\"object\" === _typeof(o)) {\n var a = i.length === o[n.inputName];\n return n.debug && console.log(\"maxLength (obj) reached:\", a), a ? (this.maxLengthReached = !0, !0) : (this.maxLengthReached = !1, !1);\n }\n }\n }, {\n key: \"isMaxLengthReached\",\n value: function value() {\n return Boolean(this.maxLengthReached);\n }\n }, {\n key: \"isTouchDevice\",\n value: function value() {\n return \"ontouchstart\" in window || navigator.maxTouchPoints;\n }\n }, {\n key: \"pointerEventsSupported\",\n value: function value() {\n return window.PointerEvent;\n }\n }, {\n key: \"camelCase\",\n value: function value(t) {\n return !!t && t.toLowerCase().trim().split(/[.\\-_\\s]/g).reduce(function (t, e) {\n return e.length ? t + e[0].toUpperCase() + e.slice(1) : t;\n });\n }\n }]) && _defineProperties(t.prototype, e), n && _defineProperties(t, n), Utilities;\n }();\n\n function PhysicalKeyboard_defineProperties(t, e) {\n for (var n = 0; n < e.length; n++) {\n var o = e[n];\n o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(t, o.key, o);\n }\n }\n\n var i = function () {\n function PhysicalKeyboard(t) {\n var e = t.dispatch,\n n = t.getOptions;\n !function (t, e) {\n if (!(t instanceof e)) throw new TypeError(\"Cannot call a class as a function\");\n }(this, PhysicalKeyboard), this.dispatch = e, this.getOptions = n, o.bindMethods(PhysicalKeyboard, this);\n }\n\n var t, e, n;\n return t = PhysicalKeyboard, (e = [{\n key: \"handleHighlightKeyDown\",\n value: function value(t) {\n var e = this.getOptions(),\n n = this.getSimpleKeyboardLayoutKey(t);\n this.dispatch(function (t) {\n var o = t.getButtonElement(n) || t.getButtonElement(\"{\".concat(n, \"}\"));\n o && (o.style.backgroundColor = e.physicalKeyboardHighlightBgColor || \"#9ab4d0\", o.style.color = e.physicalKeyboardHighlightTextColor || \"white\");\n });\n }\n }, {\n key: \"handleHighlightKeyUp\",\n value: function value(t) {\n var e = this.getSimpleKeyboardLayoutKey(t);\n this.dispatch(function (t) {\n var n = t.getButtonElement(e) || t.getButtonElement(\"{\".concat(e, \"}\"));\n n && n.removeAttribute && n.removeAttribute(\"style\");\n });\n }\n }, {\n key: \"getSimpleKeyboardLayoutKey\",\n value: function value(t) {\n var e;\n return ((e = t.code.includes(\"Numpad\") || t.code.includes(\"Shift\") || t.code.includes(\"Space\") || t.code.includes(\"Backspace\") || t.code.includes(\"Control\") || t.code.includes(\"Alt\") || t.code.includes(\"Meta\") ? t.code : t.key) !== e.toUpperCase() || \"F\" === t.code[0] && Number.isInteger(Number(t.code[1])) && t.code.length <= 3) && (e = e.toLowerCase()), e;\n }\n }]) && PhysicalKeyboard_defineProperties(t.prototype, e), n && PhysicalKeyboard_defineProperties(t, n), PhysicalKeyboard;\n }();\n\n function KeyboardLayout_defineProperties(t, e) {\n for (var n = 0; n < e.length; n++) {\n var o = e[n];\n o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(t, o.key, o);\n }\n }\n\n var s = function () {\n function KeyboardLayout() {\n !function (t, e) {\n if (!(t instanceof e)) throw new TypeError(\"Cannot call a class as a function\");\n }(this, KeyboardLayout);\n }\n\n var t, e, n;\n return t = KeyboardLayout, n = [{\n key: \"getDefaultLayout\",\n value: function value() {\n return {\n default: [\"` 1 2 3 4 5 6 7 8 9 0 - = {bksp}\", \"{tab} q w e r t y u i o p [ ] \\\\\", \"{lock} a s d f g h j k l ; ' {enter}\", \"{shift} z x c v b n m , . / {shift}\", \".com @ {space}\"],\n shift: [\"~ ! @ # $ % ^ & * ( ) _ + {bksp}\", \"{tab} Q W E R T Y U I O P { } |\", '{lock} A S D F G H J K L : \" {enter}', \"{shift} Z X C V B N M < > ? {shift}\", \".com @ {space}\"]\n };\n }\n }], (e = null) && KeyboardLayout_defineProperties(t.prototype, e), n && KeyboardLayout_defineProperties(t, n), KeyboardLayout;\n }();\n\n function _toConsumableArray(t) {\n return function (t) {\n if (Array.isArray(t)) {\n for (var e = 0, n = new Array(t.length); e < t.length; e++) {\n n[e] = t[e];\n }\n\n return n;\n }\n }(t) || function (t) {\n if (Symbol.iterator in Object(t) || \"[object Arguments]\" === Object.prototype.toString.call(t)) return Array.from(t);\n }(t) || function () {\n throw new TypeError(\"Invalid attempt to spread non-iterable instance\");\n }();\n }\n\n function Keyboard_typeof(t) {\n return (Keyboard_typeof = \"function\" === typeof Symbol && \"symbol\" === _typeof2(Symbol.iterator) ? function (t) {\n return _typeof2(t);\n } : function (t) {\n return t && \"function\" === typeof Symbol && t.constructor === Symbol && t !== Symbol.prototype ? \"symbol\" : _typeof2(t);\n })(t);\n }\n\n function Keyboard_classCallCheck(t, e) {\n if (!(t instanceof e)) throw new TypeError(\"Cannot call a class as a function\");\n }\n\n function Keyboard_defineProperties(t, e) {\n for (var n = 0; n < e.length; n++) {\n var o = e[n];\n o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(t, o.key, o);\n }\n }\n\n function _defineProperty(t, e, n) {\n return e in t ? Object.defineProperty(t, e, {\n value: n,\n enumerable: !0,\n configurable: !0,\n writable: !0\n }) : t[e] = n, t;\n }\n\n var a = function () {\n function SimpleKeyboard() {\n var t = this;\n Keyboard_classCallCheck(this, SimpleKeyboard), _defineProperty(this, \"getOptions\", function () {\n return t.options;\n }), _defineProperty(this, \"getCaretPosition\", function () {\n return t.caretPosition;\n }), _defineProperty(this, \"registerModule\", function (e, n) {\n t.modules[e] || (t.modules[e] = {}), n(t.modules[e]);\n });\n var e = \"string\" === typeof (arguments.length <= 0 ? void 0 : arguments[0]) ? arguments.length <= 0 ? void 0 : arguments[0] : \".simple-keyboard\",\n n = \"object\" === Keyboard_typeof(arguments.length <= 0 ? void 0 : arguments[0]) ? arguments.length <= 0 ? void 0 : arguments[0] : arguments.length <= 1 ? void 0 : arguments[1];\n if (n || (n = {}), this.utilities = new o({\n getOptions: this.getOptions,\n getCaretPosition: this.getCaretPosition,\n dispatch: this.dispatch\n }), this.caretPosition = null, this.keyboardDOM = document.querySelector(e), this.options = n, this.options.layoutName = this.options.layoutName || \"default\", this.options.theme = this.options.theme || \"hg-theme-default\", this.options.inputName = this.options.inputName || \"default\", this.options.preventMouseDownDefault = this.options.preventMouseDownDefault || !1, this.keyboardPluginClasses = \"\", o.bindMethods(SimpleKeyboard, this), this.input = {}, this.input[this.options.inputName] = \"\", this.keyboardDOMClass = e.split(\".\").join(\"\"), this.buttonElements = {}, window.SimpleKeyboardInstances || (window.SimpleKeyboardInstances = {}), this.currentInstanceName = this.utilities.camelCase(this.keyboardDOMClass), window.SimpleKeyboardInstances[this.currentInstanceName] = this, this.allKeyboardInstances = window.SimpleKeyboardInstances, this.keyboardInstanceNames = Object.keys(window.SimpleKeyboardInstances), this.isFirstKeyboardInstance = this.keyboardInstanceNames[0] === this.currentInstanceName, this.physicalKeyboard = new i({\n dispatch: this.dispatch,\n getOptions: this.getOptions\n }), !this.keyboardDOM) throw console.warn('\"'.concat(e, '\" was not found in the DOM.')), new Error(\"KEYBOARD_DOM_ERROR\");\n this.render(), this.modules = {}, this.loadModules();\n }\n\n var t, e, n;\n return t = SimpleKeyboard, (e = [{\n key: \"handleButtonClicked\",\n value: function value(t) {\n var e = this.options.debug;\n if (\"{//}\" === t) return !1;\n \"function\" === typeof this.options.onKeyPress && this.options.onKeyPress(t), this.input[this.options.inputName] || (this.input[this.options.inputName] = \"\");\n var n = this.utilities.getUpdatedInput(t, this.input[this.options.inputName], this.caretPosition);\n\n if (this.input[this.options.inputName] !== n && (!this.options.inputPattern || this.options.inputPattern && this.inputPatternIsValid(n))) {\n if (this.options.maxLength && this.utilities.handleMaxLength(this.input, n)) return !1;\n this.input[this.options.inputName] = this.utilities.getUpdatedInput(t, this.input[this.options.inputName], this.caretPosition, !0), e && console.log(\"Input changed:\", this.input), this.options.syncInstanceInputs && this.syncInstanceInputs(), \"function\" === typeof this.options.onChange && this.options.onChange(this.input[this.options.inputName]), \"function\" === typeof this.options.onChangeAll && this.options.onChangeAll(this.input);\n }\n\n e && console.log(\"Key pressed:\", t);\n }\n }, {\n key: \"handleButtonMouseDown\",\n value: function value(t, e) {\n var n = this;\n this.options.preventMouseDownDefault && e.preventDefault(), this.options.stopMouseDownPropagation && e.stopPropagation(), e && e.target.classList.add(this.activeButtonClass), this.isMouseHold = !0, this.holdInteractionTimeout && clearTimeout(this.holdInteractionTimeout), this.holdTimeout && clearTimeout(this.holdTimeout), this.options.disableButtonHold || (this.holdTimeout = setTimeout(function () {\n !n.isMouseHold || (t.includes(\"{\") || t.includes(\"}\")) && \"{delete}\" !== t && \"{backspace}\" !== t && \"{bksp}\" !== t && \"{space}\" !== t && \"{tab}\" !== t || (n.options.debug && console.log(\"Button held:\", t), n.handleButtonHold(t, e)), clearTimeout(n.holdTimeout);\n }, 500));\n }\n }, {\n key: \"handleButtonMouseUp\",\n value: function value(t) {\n var e = this;\n this.recurseButtons(function (t) {\n t.classList.remove(e.activeButtonClass);\n }), this.isMouseHold = !1, this.holdInteractionTimeout && clearTimeout(this.holdInteractionTimeout), t && \"function\" === typeof this.options.onKeyReleased && this.options.onKeyReleased(t);\n }\n }, {\n key: \"handleKeyboardContainerMouseDown\",\n value: function value(t) {\n this.options.preventMouseDownDefault && t.preventDefault();\n }\n }, {\n key: \"handleButtonHold\",\n value: function value(t) {\n var e = this;\n this.holdInteractionTimeout && clearTimeout(this.holdInteractionTimeout), this.holdInteractionTimeout = setTimeout(function () {\n e.isMouseHold ? (e.handleButtonClicked(t), e.handleButtonHold(t)) : clearTimeout(e.holdInteractionTimeout);\n }, 100);\n }\n }, {\n key: \"syncInstanceInputs\",\n value: function value() {\n var t = this;\n this.dispatch(function (e) {\n e.replaceInput(t.input), e.caretPosition = t.caretPosition;\n });\n }\n }, {\n key: \"clearInput\",\n value: function value(t) {\n t = t || this.options.inputName, this.input[t] = \"\", this.caretPosition = 0, this.options.syncInstanceInputs && this.syncInstanceInputs();\n }\n }, {\n key: \"getInput\",\n value: function value(t) {\n return t = t || this.options.inputName, this.options.syncInstanceInputs && this.syncInstanceInputs(), this.input[t];\n }\n }, {\n key: \"setInput\",\n value: function value(t, e) {\n e = e || this.options.inputName, this.input[e] = t, this.options.syncInstanceInputs && this.syncInstanceInputs();\n }\n }, {\n key: \"replaceInput\",\n value: function value(t) {\n this.input = t;\n }\n }, {\n key: \"setOptions\",\n value: function value(t) {\n t = t || {}, this.options = Object.assign(this.options, t), this.onSetOptions(t), this.render();\n }\n }, {\n key: \"onSetOptions\",\n value: function value(t) {\n t.inputName && (this.options.debug && console.log(\"inputName changed. caretPosition reset.\"), this.caretPosition = null);\n }\n }, {\n key: \"clear\",\n value: function value() {\n this.keyboardDOM.innerHTML = \"\", this.keyboardDOM.className = this.keyboardDOMClass, this.buttonElements = {};\n }\n }, {\n key: \"dispatch\",\n value: function value(t) {\n if (!window.SimpleKeyboardInstances) throw console.warn(\"SimpleKeyboardInstances is not defined. Dispatch cannot be called.\"), new Error(\"INSTANCES_VAR_ERROR\");\n return Object.keys(window.SimpleKeyboardInstances).forEach(function (e) {\n t(window.SimpleKeyboardInstances[e], e);\n });\n }\n }, {\n key: \"addButtonTheme\",\n value: function value(t, e) {\n var n = this;\n if (!e || !t) return !1;\n t.split(\" \").forEach(function (o) {\n e.split(\" \").forEach(function (e) {\n n.options.buttonTheme || (n.options.buttonTheme = []);\n var i = !1;\n n.options.buttonTheme.map(function (t) {\n if (t.class.split(\" \").includes(e)) {\n i = !0;\n var n = t.buttons.split(\" \");\n n.includes(o) || (i = !0, n.push(o), t.buttons = n.join(\" \"));\n }\n\n return t;\n }), i || n.options.buttonTheme.push({\n class: e,\n buttons: t\n });\n });\n }), this.render();\n }\n }, {\n key: \"removeButtonTheme\",\n value: function value(t, e) {\n var n = this;\n if (!t && !e) return this.options.buttonTheme = [], this.render(), !1;\n t && Array.isArray(this.options.buttonTheme) && this.options.buttonTheme.length && (t.split(\" \").forEach(function (t, o) {\n n.options.buttonTheme.map(function (o, i) {\n if (e && e.includes(o.class) || !e) {\n var s = o.buttons.split(\" \").filter(function (e) {\n return e !== t;\n });\n s.length ? o.buttons = s.join(\" \") : (n.options.buttonTheme.splice(i, 1), o = null);\n }\n\n return o;\n });\n }), this.render());\n }\n }, {\n key: \"getButtonElement\",\n value: function value(t) {\n var e,\n n = this.buttonElements[t];\n return n && (e = n.length > 1 ? n : n[0]), e;\n }\n }, {\n key: \"inputPatternIsValid\",\n value: function value(t) {\n var e,\n n = this.options.inputPattern;\n\n if ((e = n instanceof RegExp ? n : n[this.options.inputName]) && t) {\n var o = e.test(t);\n return this.options.debug && console.log('inputPattern (\"'.concat(e, '\"): ').concat(o ? \"passed\" : \"did not pass!\")), o;\n }\n\n return !0;\n }\n }, {\n key: \"setEventListeners\",\n value: function value() {\n !this.isFirstKeyboardInstance && this.allKeyboardInstances || (this.options.debug && console.log(\"Caret handling started (\".concat(this.keyboardDOMClass, \")\")), document.addEventListener(\"keyup\", this.handleKeyUp), document.addEventListener(\"keydown\", this.handleKeyDown), document.addEventListener(\"mouseup\", this.handleMouseUp), document.addEventListener(\"touchend\", this.handleTouchEnd));\n }\n }, {\n key: \"handleKeyUp\",\n value: function value(t) {\n this.caretEventHandler(t), this.options.physicalKeyboardHighlight && this.physicalKeyboard.handleHighlightKeyUp(t);\n }\n }, {\n key: \"handleKeyDown\",\n value: function value(t) {\n this.options.physicalKeyboardHighlight && this.physicalKeyboard.handleHighlightKeyDown(t);\n }\n }, {\n key: \"handleMouseUp\",\n value: function value(t) {\n this.caretEventHandler(t);\n }\n }, {\n key: \"handleTouchEnd\",\n value: function value(t) {\n this.caretEventHandler(t);\n }\n }, {\n key: \"caretEventHandler\",\n value: function value(t) {\n var e;\n t.target.tagName && (e = t.target.tagName.toLowerCase()), this.dispatch(function (n) {\n n.isMouseHold && (n.isMouseHold = !1), \"textarea\" !== e && \"input\" !== e || n.options.disableCaretPositioning ? n.options.disableCaretPositioning && (n.caretPosition = null) : (n.caretPosition = t.target.selectionStart, n.options.debug && console.log(\"Caret at: \", t.target.selectionStart, t.target.tagName.toLowerCase(), \"(\".concat(n.keyboardDOMClass, \")\")));\n });\n }\n }, {\n key: \"recurseButtons\",\n value: function value(t) {\n var e = this;\n if (!t) return !1;\n Object.keys(this.buttonElements).forEach(function (n) {\n return e.buttonElements[n].forEach(t);\n });\n }\n }, {\n key: \"destroy\",\n value: function value() {\n this.options.debug && console.log(\"Destroying simple-keyboard instance: \".concat(this.currentInstanceName)), document.removeEventListener(\"keyup\", this.handleKeyUp), document.removeEventListener(\"keydown\", this.handleKeyDown), document.removeEventListener(\"mouseup\", this.handleMouseUp), document.removeEventListener(\"touchend\", this.handleTouchEnd), document.onpointerup = null, document.ontouchend = null, document.ontouchcancel = null, document.onmouseup = null;\n\n var deleteButton = function deleteButton(t) {\n t.onpointerdown = null, t.onpointerup = null, t.onpointercancel = null, t.ontouchstart = null, t.ontouchend = null, t.ontouchcancel = null, t.onclick = null, t.onmousedown = null, t.onmouseup = null, t.remove(), t = null;\n };\n\n this.recurseButtons(deleteButton), this.recurseButtons = null, deleteButton = null, this.keyboardDOM.onpointerdown = null, this.keyboardDOM.ontouchstart = null, this.keyboardDOM.onmousedown = null, this.clear(), window.SimpleKeyboardInstances[this.currentInstanceName] = null, delete window.SimpleKeyboardInstances[this.currentInstanceName], this.initialized = !1;\n }\n }, {\n key: \"getButtonThemeClasses\",\n value: function value(t) {\n var e = this.options.buttonTheme,\n n = [];\n return Array.isArray(e) && e.forEach(function (e) {\n if (e.class && \"string\" === typeof e.class && e.buttons && \"string\" === typeof e.buttons) {\n var o = e.class.split(\" \");\n e.buttons.split(\" \").includes(t) && (n = [].concat(_toConsumableArray(n), _toConsumableArray(o)));\n } else console.warn('Incorrect \"buttonTheme\". Please check the documentation.', e);\n }), n;\n }\n }, {\n key: \"setDOMButtonAttributes\",\n value: function value(t, e) {\n var n = this.options.buttonAttributes;\n Array.isArray(n) && n.forEach(function (n) {\n n.attribute && \"string\" === typeof n.attribute && n.value && \"string\" === typeof n.value && n.buttons && \"string\" === typeof n.buttons ? n.buttons.split(\" \").includes(t) && e(n.attribute, n.value) : console.warn('Incorrect \"buttonAttributes\". Please check the documentation.', n);\n });\n }\n }, {\n key: \"onTouchDeviceDetected\",\n value: function value() {\n this.processAutoTouchEvents(), this.disableContextualWindow();\n }\n }, {\n key: \"disableContextualWindow\",\n value: function value() {\n window.oncontextmenu = function (t) {\n if (t.target.classList.contains(\"hg-button\")) return t.preventDefault(), t.stopPropagation(), !1;\n };\n }\n }, {\n key: \"processAutoTouchEvents\",\n value: function value() {\n this.options.autoUseTouchEvents && (this.options.useTouchEvents = !0, this.options.debug && console.log(\"autoUseTouchEvents: Touch device detected, useTouchEvents enabled.\"));\n }\n }, {\n key: \"onInit\",\n value: function value() {\n this.options.debug && console.log(\"\".concat(this.keyboardDOMClass, \" Initialized\")), this.setEventListeners(), \"function\" === typeof this.options.onInit && this.options.onInit();\n }\n }, {\n key: \"beforeFirstRender\",\n value: function value() {\n this.utilities.isTouchDevice() && this.onTouchDeviceDetected(), \"function\" === typeof this.options.beforeFirstRender && this.options.beforeFirstRender(), this.isFirstKeyboardInstance && this.utilities.pointerEventsSupported() && !this.options.useTouchEvents && !this.options.useMouseEvents && this.options.debug && console.log(\"Using PointerEvents as it is supported by this browser\"), this.options.useTouchEvents && this.options.debug && console.log(\"useTouchEvents has been enabled. Only touch events will be used.\");\n }\n }, {\n key: \"beforeRender\",\n value: function value() {\n \"function\" === typeof this.options.beforeRender && this.options.beforeRender();\n }\n }, {\n key: \"onRender\",\n value: function value() {\n \"function\" === typeof this.options.onRender && this.options.onRender();\n }\n }, {\n key: \"onModulesLoaded\",\n value: function value() {\n \"function\" === typeof this.options.onModulesLoaded && this.options.onModulesLoaded();\n }\n }, {\n key: \"loadModules\",\n value: function value() {\n var t = this;\n Array.isArray(this.options.modules) && (this.options.modules.forEach(function (e) {\n var n = new e();\n\n if (n.constructor.name && \"Function\" !== n.constructor.name) {\n var o = \"module-\".concat(t.utilities.camelCase(n.constructor.name));\n t.keyboardPluginClasses = t.keyboardPluginClasses + \" \".concat(o);\n }\n\n n.init(t);\n }), this.keyboardPluginClasses = this.keyboardPluginClasses + \" modules-loaded\", this.render(), this.onModulesLoaded());\n }\n }, {\n key: \"getModuleProp\",\n value: function value(t, e) {\n return !!this.modules[t] && this.modules[t][e];\n }\n }, {\n key: \"getModulesList\",\n value: function value() {\n return Object.keys(this.modules);\n }\n }, {\n key: \"parseRowDOMContainers\",\n value: function value(t, e, n, o) {\n var i = this,\n s = Array.from(t.children),\n a = 0;\n return s.length && n.forEach(function (n, r) {\n var u = o[r];\n if (!u || !(u > n)) return !1;\n var c = n - a,\n l = u - a,\n h = document.createElement(\"div\");\n h.className += \"hg-button-container\";\n var d = \"\".concat(i.options.layoutName, \"-r\").concat(e, \"c\").concat(r);\n h.setAttribute(\"data-skUID\", d);\n var p = s.splice(c, l - c + 1);\n a = l - c, p.forEach(function (t) {\n return h.appendChild(t);\n }), s.splice(c, 0, h), t.innerHTML = \"\", s.forEach(function (e) {\n return t.appendChild(e);\n }), i.options.debug && console.log(\"rowDOMContainer\", p, c, l, a + 1);\n }), t;\n }\n }, {\n key: \"render\",\n value: function value() {\n var t = this;\n this.clear(), this.initialized || this.beforeFirstRender(), this.beforeRender();\n var e = \"hg-layout-\".concat(this.options.layoutName),\n n = this.options.layout || s.getDefaultLayout(),\n o = this.options.useTouchEvents || !1,\n i = o ? \"hg-touch-events\" : \"\",\n a = this.options.useMouseEvents || !1,\n r = this.options.disableRowButtonContainers;\n this.keyboardDOM.className += \" \".concat(this.options.theme, \" \").concat(e, \" \").concat(this.keyboardPluginClasses, \" \").concat(i), n[this.options.layoutName].forEach(function (e, n) {\n var i = e.split(\" \"),\n s = document.createElement(\"div\");\n s.className += \"hg-row\";\n var u = [],\n c = [];\n i.forEach(function (e, i) {\n var l,\n h = !r && e.includes(\"[\") && e.length > 1,\n d = !r && e.includes(\"]\") && e.length > 1;\n h && (u.push(i), e = e.replace(/\\[/g, \"\")), d && (c.push(i), e = e.replace(/\\]/g, \"\"));\n var p = t.utilities.getButtonClass(e),\n f = t.utilities.getButtonDisplayName(e, t.options.display, t.options.mergeDisplay),\n y = t.options.useButtonTag ? \"button\" : \"div\",\n b = document.createElement(y);\n b.className += \"hg-button \".concat(p), (l = b.classList).add.apply(l, _toConsumableArray(t.getButtonThemeClasses(e))), t.setDOMButtonAttributes(e, function (t, e) {\n b.setAttribute(t, e);\n }), t.activeButtonClass = \"hg-activeButton\", !t.utilities.pointerEventsSupported() || o || a ? o ? (b.ontouchstart = function (n) {\n t.handleButtonClicked(e), t.handleButtonMouseDown(e, n);\n }, b.ontouchend = function () {\n t.handleButtonMouseUp(e);\n }, b.ontouchcancel = function () {\n t.handleButtonMouseUp(e);\n }) : (b.onclick = function () {\n t.isMouseHold = !1, t.handleButtonClicked(e);\n }, b.onmousedown = function (n) {\n t.handleButtonMouseDown(e, n);\n }, b.onmouseup = function () {\n t.handleButtonMouseUp(e);\n }) : (b.onpointerdown = function (n) {\n t.handleButtonClicked(e), t.handleButtonMouseDown(e, n);\n }, b.onpointerup = function () {\n t.handleButtonMouseUp(e);\n }, b.onpointercancel = function () {\n t.handleButtonMouseUp(e);\n }), b.setAttribute(\"data-skBtn\", e);\n var m = \"\".concat(t.options.layoutName, \"-r\").concat(n, \"b\").concat(i);\n b.setAttribute(\"data-skBtnUID\", m);\n var g = document.createElement(\"span\");\n g.innerHTML = f, b.appendChild(g), t.buttonElements[e] || (t.buttonElements[e] = []), t.buttonElements[e].push(b), s.appendChild(b);\n }), s = t.parseRowDOMContainers(s, n, u, c), t.keyboardDOM.appendChild(s);\n }), this.onRender(), this.initialized || (this.initialized = !0, !this.utilities.pointerEventsSupported() || o || a ? o ? (document.ontouchend = function () {\n return t.handleButtonMouseUp();\n }, document.ontouchcancel = function () {\n return t.handleButtonMouseUp();\n }, this.keyboardDOM.ontouchstart = function (e) {\n return t.handleKeyboardContainerMouseDown(e);\n }) : o || (document.onmouseup = function () {\n return t.handleButtonMouseUp();\n }, this.keyboardDOM.onmousedown = function (e) {\n return t.handleKeyboardContainerMouseDown(e);\n }) : (document.onpointerup = function () {\n return t.handleButtonMouseUp();\n }, this.keyboardDOM.onpointerdown = function (e) {\n return t.handleKeyboardContainerMouseDown(e);\n }), this.onInit());\n }\n }]) && Keyboard_defineProperties(t.prototype, e), n && Keyboard_defineProperties(t, n), SimpleKeyboard;\n }();\n\n e.default = a;\n }]);\n});","module.exports = function (module) {\n if (!module.webpackPolyfill) {\n module.deprecate = function () {};\n\n module.paths = []; // module.parent = undefined by default\n\n if (!module.children) module.children = [];\n Object.defineProperty(module, \"loaded\", {\n enumerable: true,\n get: function get() {\n return module.l;\n }\n });\n Object.defineProperty(module, \"id\", {\n enumerable: true,\n get: function get() {\n return module.i;\n }\n });\n module.webpackPolyfill = 1;\n }\n\n return module;\n};","function _typeof(obj) {\n \"@babel/helpers - typeof\";\n\n if (typeof Symbol === \"function\" && typeof Symbol.iterator === \"symbol\") {\n module.exports = _typeof = function _typeof(obj) {\n return typeof obj;\n };\n } else {\n module.exports = _typeof = function _typeof(obj) {\n return obj && typeof Symbol === \"function\" && obj.constructor === Symbol && obj !== Symbol.prototype ? \"symbol\" : typeof obj;\n };\n }\n\n return _typeof(obj);\n}\n\nmodule.exports = _typeof;","export const parseProps = props => ({\n ...props,\n theme: `simple-keyboard ${props.theme || \"hg-theme-default\"}`\n});\n\nexport const propsChanged = (prevProps, props) => {\n const cleanProps = sourceObj =>\n JSON.stringify({\n ...sourceObj,\n stateToIgnore: null\n });\n\n return cleanProps(props) !== cleanProps(prevProps);\n};\n","import React, { useEffect, useRef } from \"react\";\nimport Keyboard from \"simple-keyboard\";\nimport { parseProps, propsChanged } from \"../services/Utilities\";\nimport \"simple-keyboard/build/css/index.css\";\n\nconst KeyboardReact = props => {\n const cssClass = props.baseClass || \"react-simple-keyboard\";\n const initRef = useRef();\n const keyboardRef = useRef();\n const previousProps = useRef(props);\n\n useEffect(() => {\n /**\n * Initialize simple-keyboard\n */\n if (!initRef.current) {\n initRef.current = true;\n props.debug && console.log(\"ReactSimpleKeyboard: Init\");\n keyboardRef.current = new Keyboard(`.${cssClass}`, parseProps(props));\n props.keyboardRef && props.keyboardRef(keyboardRef.current);\n }\n\n /**\n * Only trigger render if props changed\n */\n if (propsChanged(previousProps.current, props)) {\n let keyboard = keyboardRef.current;\n previousProps.current = props;\n keyboard.setOptions(parseProps(props));\n props.debug && console.log(\"ReactSimpleKeyboard: Rendered\");\n }\n }, [initRef, cssClass, previousProps, props]);\n\n return
;\n};\n\nexport default KeyboardReact;\n","import Keyboard from \"./components/Keyboard\";\n\nexport default Keyboard;\n"],"sourceRoot":""} \ No newline at end of file +{"version":3,"sources":["../../webpack/universalModuleDefinition","../../webpack/bootstrap","../../external {\"root\":\"React\",\"commonjs2\":\"react\",\"commonjs\":\"react\",\"amd\":\"react\"}","../../node_modules/simple-keyboard/build/index.js","../../node_modules/webpack/buildin/module.js","../../node_modules/babel-preset-react-app/node_modules/@babel/runtime/helpers/typeof.js","services/Utilities.js","components/Keyboard.js","index.js"],"names":["root","factory","exports","module","require","define","amd","window","__WEBPACK_EXTERNAL_MODULE__0__","installedModules","__webpack_require__","moduleId","i","l","modules","call","m","c","d","name","getter","o","Object","defineProperty","enumerable","get","r","Symbol","toStringTag","value","t","mode","__esModule","ns","create","key","bind","n","object","property","prototype","hasOwnProperty","p","s","e","_typeof2","default","_typeof","iterator","constructor","_defineProperties","length","configurable","writable","Utilities","getOptions","getCaretPosition","dispatch","TypeError","this","bindMethods","a","getOwnPropertyNames","next","done","u","return","includes","replace","concat","assign","getDefaultDiplay","removeAt","addStringAt","tabCharOnTab","newLineOnEnter","Number","isInteger","updateCaretPosAction","caretPosition","debug","console","log","keyboardDOMClass","slice","join","isMaxLengthReached","updateCaretPos","substring","match","substr","maxLength","inputName","maxLengthReached","Boolean","navigator","maxTouchPoints","PointerEvent","toLowerCase","trim","split","reduce","toUpperCase","PhysicalKeyboard_defineProperties","PhysicalKeyboard","getSimpleKeyboardLayoutKey","getButtonElement","style","backgroundColor","physicalKeyboardHighlightBgColor","color","physicalKeyboardHighlightTextColor","removeAttribute","code","_toConsumableArray","Array","isArray","toString","from","Keyboard_classCallCheck","Keyboard_defineProperties","_defineProperty","SimpleKeyboard","document","querySelector","HTMLDivElement","className","warn","Error","keyboardDOM","options","arguments","filter","handleParams","utilities","layoutName","theme","preventMouseDownDefault","keyboardPluginClasses","input","buttonElements","SimpleKeyboardInstances","currentInstanceName","camelCase","allKeyboardInstances","keyboardInstanceNames","keys","isFirstKeyboardInstance","physicalKeyboard","render","loadModules","onKeyPress","getUpdatedInput","inputPattern","inputPatternIsValid","handleMaxLength","syncInstanceInputs","onChange","onChangeAll","preventDefault","stopMouseDownPropagation","stopPropagation","target","classList","add","activeButtonClass","isMouseHold","holdInteractionTimeout","clearTimeout","holdTimeout","disableButtonHold","setTimeout","handleButtonHold","recurseButtons","remove","onKeyReleased","handleButtonClicked","replaceInput","onSetOptions","innerHTML","forEach","buttonTheme","map","class","buttons","push","splice","RegExp","test","addEventListener","handleKeyUp","handleKeyDown","handleMouseUp","handleTouchEnd","caretEventHandler","physicalKeyboardHighlight","handleHighlightKeyUp","handleHighlightKeyDown","tagName","disableCaretPositioning","selectionStart","removeEventListener","onpointerup","ontouchend","ontouchcancel","onmouseup","deleteButton","onpointerdown","onpointercancel","ontouchstart","onclick","onmousedown","clear","initialized","buttonAttributes","attribute","processAutoTouchEvents","disableContextualWindow","oncontextmenu","contains","autoUseTouchEvents","useTouchEvents","setEventListeners","onInit","isTouchDevice","onTouchDeviceDetected","beforeFirstRender","pointerEventsSupported","useMouseEvents","beforeRender","onRender","onModulesLoaded","init","children","h","createElement","setAttribute","appendChild","layout","shift","disableRowButtonContainers","getKeyboardClassString","getButtonClass","f","getButtonDisplayName","display","mergeDisplay","y","useButtonTag","b","apply","getButtonThemeClasses","setDOMButtonAttributes","handleButtonMouseDown","handleButtonMouseUp","g","parseRowDOMContainers","handleKeyboardContainerMouseDown","webpackPolyfill","deprecate","paths","obj","parseProps","props","KeyboardReact","cssClass","baseClass","initRef","useRef","keyboardRef","previousProps","useEffect","current","Keyboard","prevProps","cleanProps","sourceObj","JSON","stringify","stateToIgnore","propsChanged","keyboard","setOptions"],"mappings":";;;;;;;;;;;CAAA,SAA2CA,EAAMC,GAC1B,kBAAZC,SAA0C,kBAAXC,OACxCA,OAAOD,QAAUD,EAAQG,QAAQ,UACR,oBAAXC,QAAyBA,OAAOC,IAC9CD,OAAO,sBAAuB,CAAC,SAAUJ,GACf,kBAAZC,QACdA,QAA6B,oBAAID,EAAQG,QAAQ,UAEjDJ,EAA0B,oBAAIC,EAAQD,EAAY,OARpD,CASGO,QAAQ,SAASC,GACpB,O,YCTE,IAAIC,EAAmB,GAGvB,SAASC,oBAAoBC,GAG5B,GAAGF,EAAiBE,GACnB,OAAOF,EAAiBE,GAAUT,QAGnC,IAAIC,EAASM,EAAiBE,GAAY,CACzCC,EAAGD,EACHE,GAAG,EACHX,QAAS,IAUV,OANAY,EAAQH,GAAUI,KAAKZ,EAAOD,QAASC,EAAQA,EAAOD,QAASQ,qBAG/DP,EAAOU,GAAI,EAGJV,EAAOD,QA0Df,OArDAQ,oBAAoBM,EAAIF,EAGxBJ,oBAAoBO,EAAIR,EAGxBC,oBAAoBQ,EAAI,SAAShB,EAASiB,EAAMC,GAC3CV,oBAAoBW,EAAEnB,EAASiB,IAClCG,OAAOC,eAAerB,EAASiB,EAAM,CAAEK,YAAY,EAAMC,IAAKL,KAKhEV,oBAAoBgB,EAAI,SAASxB,GACX,qBAAXyB,QAA0BA,OAAOC,aAC1CN,OAAOC,eAAerB,EAASyB,OAAOC,YAAa,CAAEC,MAAO,WAE7DP,OAAOC,eAAerB,EAAS,aAAc,CAAE2B,OAAO,KAQvDnB,oBAAoBoB,EAAI,SAASD,EAAOE,GAEvC,GADU,EAAPA,IAAUF,EAAQnB,oBAAoBmB,IAC/B,EAAPE,EAAU,OAAOF,EACpB,GAAW,EAAPE,GAA8B,kBAAVF,GAAsBA,GAASA,EAAMG,WAAY,OAAOH,EAChF,IAAII,EAAKX,OAAO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AAYG,QAC3BF,EAAcE,QAAUT,EACxBkB,EAASC,WAAWpB,WAAWC,IAC/BA,EAAMvL,OAASC,QAAQC,IAAI,oCAE5B,CAACyL,EAASF,EAAUK,EAAeP,IAE/B,yBAAKzI,UAAW2I,MC/BVQ","file":"index.js","sourcesContent":["(function webpackUniversalModuleDefinition(root, factory) {\n\tif(typeof exports === 'object' && typeof module === 'object')\n\t\tmodule.exports = factory(require(\"react\"));\n\telse if(typeof define === 'function' && define.amd)\n\t\tdefine(\"ReactSimpleKeyboard\", [\"react\"], factory);\n\telse if(typeof exports === 'object')\n\t\texports[\"ReactSimpleKeyboard\"] = factory(require(\"react\"));\n\telse\n\t\troot[\"ReactSimpleKeyboard\"] = factory(root[\"React\"]);\n})(window, function(__WEBPACK_EXTERNAL_MODULE__0__) {\nreturn "," \t// The module cache\n \tvar installedModules = {};\n\n \t// The require function\n \tfunction __webpack_require__(moduleId) {\n\n \t\t// Check if module is in cache\n \t\tif(installedModules[moduleId]) {\n \t\t\treturn installedModules[moduleId].exports;\n \t\t}\n \t\t// Create a new module (and put it into the cache)\n \t\tvar module = installedModules[moduleId] = {\n \t\t\ti: moduleId,\n \t\t\tl: false,\n \t\t\texports: {}\n \t\t};\n\n \t\t// Execute the module function\n \t\tmodules[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n \t\t// Flag the module as loaded\n \t\tmodule.l = true;\n\n \t\t// Return the exports of the module\n \t\treturn module.exports;\n \t}\n\n\n \t// expose the modules object (__webpack_modules__)\n \t__webpack_require__.m = modules;\n\n \t// expose the module cache\n \t__webpack_require__.c = installedModules;\n\n \t// define getter function for harmony exports\n \t__webpack_require__.d = function(exports, name, getter) {\n \t\tif(!__webpack_require__.o(exports, name)) {\n \t\t\tObject.defineProperty(exports, name, { enumerable: true, get: getter });\n \t\t}\n \t};\n\n \t// define __esModule on exports\n \t__webpack_require__.r = function(exports) {\n \t\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n \t\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n \t\t}\n \t\tObject.defineProperty(exports, '__esModule', { value: true });\n \t};\n\n \t// create a fake namespace object\n \t// mode & 1: value is a module id, require it\n \t// mode & 2: merge all properties of value into the ns\n \t// mode & 4: return value when already ns object\n \t// mode & 8|1: behave like require\n \t__webpack_require__.t = function(value, mode) {\n \t\tif(mode & 1) value = __webpack_require__(value);\n \t\tif(mode & 8) return value;\n \t\tif((mode & 4) && typeof value === 'object' && value && value.__esModule) return value;\n \t\tvar ns = Object.create(null);\n \t\t__webpack_require__.r(ns);\n \t\tObject.defineProperty(ns, 'default', { enumerable: true, value: value });\n \t\tif(mode & 2 && typeof value != 'string') for(var key in value) __webpack_require__.d(ns, key, function(key) { return value[key]; }.bind(null, key));\n \t\treturn ns;\n \t};\n\n \t// getDefaultExport function for compatibility with non-harmony modules\n \t__webpack_require__.n = function(module) {\n \t\tvar getter = module && module.__esModule ?\n \t\t\tfunction getDefault() { return module['default']; } :\n \t\t\tfunction getModuleExports() { return module; };\n \t\t__webpack_require__.d(getter, 'a', getter);\n \t\treturn getter;\n \t};\n\n \t// Object.prototype.hasOwnProperty.call\n \t__webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };\n\n \t// __webpack_public_path__\n \t__webpack_require__.p = \"\";\n\n\n \t// Load entry module and return exports\n \treturn __webpack_require__(__webpack_require__.s = 2);\n","module.exports = __WEBPACK_EXTERNAL_MODULE__0__;","var _typeof2 = require(\"C:\\\\Dev\\\\react-simple-keyboard\\\\node_modules\\\\babel-preset-react-app\\\\node_modules\\\\@babel\\\\runtime/helpers/typeof\");\n\n/*!\n * \n * simple-keyboard v2.28.2\n * https://github.com/hodgef/simple-keyboard\n * \n * Copyright (c) Francisco Hodge (https://github.com/hodgef)\n * \n * This source code is licensed under the MIT license found in the\n * LICENSE file in the root directory of this source tree.\n * \n */\n!function (t, e) {\n \"object\" === (typeof exports === \"undefined\" ? \"undefined\" : _typeof2(exports)) && \"object\" === (typeof module === \"undefined\" ? \"undefined\" : _typeof2(module)) ? module.exports = e() : \"function\" === typeof define && define.amd ? define(\"SimpleKeyboard\", [], e) : \"object\" === (typeof exports === \"undefined\" ? \"undefined\" : _typeof2(exports)) ? exports.SimpleKeyboard = e() : t.SimpleKeyboard = e();\n}(window, function () {\n return function (t) {\n var e = {};\n\n function __webpack_require__(n) {\n if (e[n]) return e[n].exports;\n var o = e[n] = {\n i: n,\n l: !1,\n exports: {}\n };\n return t[n].call(o.exports, o, o.exports, __webpack_require__), o.l = !0, o.exports;\n }\n\n return __webpack_require__.m = t, __webpack_require__.c = e, __webpack_require__.d = function (t, e, n) {\n __webpack_require__.o(t, e) || Object.defineProperty(t, e, {\n enumerable: !0,\n get: n\n });\n }, __webpack_require__.r = function (t) {\n \"undefined\" !== typeof Symbol && Symbol.toStringTag && Object.defineProperty(t, Symbol.toStringTag, {\n value: \"Module\"\n }), Object.defineProperty(t, \"__esModule\", {\n value: !0\n });\n }, __webpack_require__.t = function (t, e) {\n if (1 & e && (t = __webpack_require__(t)), 8 & e) return t;\n if (4 & e && \"object\" === _typeof2(t) && t && t.__esModule) return t;\n var n = Object.create(null);\n if (__webpack_require__.r(n), Object.defineProperty(n, \"default\", {\n enumerable: !0,\n value: t\n }), 2 & e && \"string\" != typeof t) for (var o in t) {\n __webpack_require__.d(n, o, function (e) {\n return t[e];\n }.bind(null, o));\n }\n return n;\n }, __webpack_require__.n = function (t) {\n var e = t && t.__esModule ? function () {\n return t.default;\n } : function () {\n return t;\n };\n return __webpack_require__.d(e, \"a\", e), e;\n }, __webpack_require__.o = function (t, e) {\n return Object.prototype.hasOwnProperty.call(t, e);\n }, __webpack_require__.p = \"\", __webpack_require__(__webpack_require__.s = 0);\n }([function (t, e, n) {\n t.exports = n(2);\n }, function (t, e, n) {}, function (t, e, n) {\n \"use strict\";\n\n n.r(e);\n n(1);\n\n function _typeof(t) {\n return (_typeof = \"function\" === typeof Symbol && \"symbol\" === _typeof2(Symbol.iterator) ? function (t) {\n return _typeof2(t);\n } : function (t) {\n return t && \"function\" === typeof Symbol && t.constructor === Symbol && t !== Symbol.prototype ? \"symbol\" : _typeof2(t);\n })(t);\n }\n\n function _defineProperties(t, e) {\n for (var n = 0; n < e.length; n++) {\n var o = e[n];\n o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(t, o.key, o);\n }\n }\n\n var o = function () {\n function Utilities(t) {\n var e = t.getOptions,\n n = t.getCaretPosition,\n o = t.dispatch;\n !function (t, e) {\n if (!(t instanceof e)) throw new TypeError(\"Cannot call a class as a function\");\n }(this, Utilities), this.getOptions = e, this.getCaretPosition = n, this.dispatch = o, Utilities.bindMethods(Utilities, this);\n }\n\n var t, e, n;\n return t = Utilities, n = [{\n key: \"bindMethods\",\n value: function value(t, e) {\n var n = !0,\n o = !1,\n i = void 0;\n\n try {\n for (var s, a = Object.getOwnPropertyNames(t.prototype)[Symbol.iterator](); !(n = (s = a.next()).done); n = !0) {\n var r = s.value;\n \"constructor\" === r || \"bindMethods\" === r || (e[r] = e[r].bind(e));\n }\n } catch (u) {\n o = !0, i = u;\n } finally {\n try {\n n || null == a.return || a.return();\n } finally {\n if (o) throw i;\n }\n }\n }\n }], (e = [{\n key: \"getButtonClass\",\n value: function value(t) {\n var e = t.includes(\"{\") && t.includes(\"}\") && \"{//}\" !== t ? \"functionBtn\" : \"standardBtn\",\n n = t.replace(\"{\", \"\").replace(\"}\", \"\"),\n o = \"\";\n return \"standardBtn\" !== e && (o = \" hg-button-\".concat(n)), \"hg-\".concat(e).concat(o);\n }\n }, {\n key: \"getDefaultDiplay\",\n value: function value() {\n return {\n \"{bksp}\": \"backspace\",\n \"{backspace}\": \"backspace\",\n \"{enter}\": \"< enter\",\n \"{shift}\": \"shift\",\n \"{shiftleft}\": \"shift\",\n \"{shiftright}\": \"shift\",\n \"{alt}\": \"alt\",\n \"{s}\": \"shift\",\n \"{tab}\": \"tab\",\n \"{lock}\": \"caps\",\n \"{capslock}\": \"caps\",\n \"{accept}\": \"Submit\",\n \"{space}\": \" \",\n \"{//}\": \" \",\n \"{esc}\": \"esc\",\n \"{escape}\": \"esc\",\n \"{f1}\": \"f1\",\n \"{f2}\": \"f2\",\n \"{f3}\": \"f3\",\n \"{f4}\": \"f4\",\n \"{f5}\": \"f5\",\n \"{f6}\": \"f6\",\n \"{f7}\": \"f7\",\n \"{f8}\": \"f8\",\n \"{f9}\": \"f9\",\n \"{f10}\": \"f10\",\n \"{f11}\": \"f11\",\n \"{f12}\": \"f12\",\n \"{numpaddivide}\": \"/\",\n \"{numlock}\": \"lock\",\n \"{arrowup}\": \"\\u2191\",\n \"{arrowleft}\": \"\\u2190\",\n \"{arrowdown}\": \"\\u2193\",\n \"{arrowright}\": \"\\u2192\",\n \"{prtscr}\": \"print\",\n \"{scrolllock}\": \"scroll\",\n \"{pause}\": \"pause\",\n \"{insert}\": \"ins\",\n \"{home}\": \"home\",\n \"{pageup}\": \"up\",\n \"{delete}\": \"del\",\n \"{end}\": \"end\",\n \"{pagedown}\": \"down\",\n \"{numpadmultiply}\": \"*\",\n \"{numpadsubtract}\": \"-\",\n \"{numpadadd}\": \"+\",\n \"{numpadenter}\": \"enter\",\n \"{period}\": \".\",\n \"{numpaddecimal}\": \".\",\n \"{numpad0}\": \"0\",\n \"{numpad1}\": \"1\",\n \"{numpad2}\": \"2\",\n \"{numpad3}\": \"3\",\n \"{numpad4}\": \"4\",\n \"{numpad5}\": \"5\",\n \"{numpad6}\": \"6\",\n \"{numpad7}\": \"7\",\n \"{numpad8}\": \"8\",\n \"{numpad9}\": \"9\"\n };\n }\n }, {\n key: \"getButtonDisplayName\",\n value: function value(t, e, n) {\n return (e = n ? Object.assign({}, this.getDefaultDiplay(), e) : e || this.getDefaultDiplay())[t] || t;\n }\n }, {\n key: \"getUpdatedInput\",\n value: function value(t, e, n, o) {\n var i = this.getOptions(),\n s = e;\n return (\"{bksp}\" === t || \"{backspace}\" === t) && s.length > 0 ? s = this.removeAt(s, n, o) : \"{space}\" === t ? s = this.addStringAt(s, \" \", n, o) : \"{tab}\" !== t || \"boolean\" === typeof i.tabCharOnTab && !1 === i.tabCharOnTab ? \"{enter}\" !== t && \"{numpadenter}\" !== t || !i.newLineOnEnter ? t.includes(\"numpad\") && Number.isInteger(Number(t[t.length - 2])) ? s = this.addStringAt(s, t[t.length - 2], n, o) : \"{numpaddivide}\" === t ? s = this.addStringAt(s, \"/\", n, o) : \"{numpadmultiply}\" === t ? s = this.addStringAt(s, \"*\", n, o) : \"{numpadsubtract}\" === t ? s = this.addStringAt(s, \"-\", n, o) : \"{numpadadd}\" === t ? s = this.addStringAt(s, \"+\", n, o) : \"{numpaddecimal}\" === t ? s = this.addStringAt(s, \".\", n, o) : \"{\" === t || \"}\" === t ? s = this.addStringAt(s, t, n, o) : t.includes(\"{\") || t.includes(\"}\") || (s = this.addStringAt(s, t, n, o)) : s = this.addStringAt(s, \"\\n\", n, o) : s = this.addStringAt(s, \"\\t\", n, o), s;\n }\n }, {\n key: \"updateCaretPos\",\n value: function value(t, e) {\n var n = this.updateCaretPosAction(t, e);\n this.dispatch(function (t) {\n t.caretPosition = n;\n });\n }\n }, {\n key: \"updateCaretPosAction\",\n value: function value(t, e) {\n var n = this.getOptions(),\n o = this.getCaretPosition();\n return e ? o > 0 && (o -= t) : o += t, n.debug && console.log(\"Caret at:\", o, \"(\".concat(this.keyboardDOMClass, \")\")), o;\n }\n }, {\n key: \"addStringAt\",\n value: function value(t, e, n, o) {\n var i;\n return n || 0 === n ? (i = [t.slice(0, n), e, t.slice(n)].join(\"\"), this.isMaxLengthReached() || o && this.updateCaretPos(e.length)) : i = t + e, i;\n }\n }, {\n key: \"removeAt\",\n value: function value(t, e, n) {\n var o;\n if (0 === this.getCaretPosition()) return t;\n var i = /([\\uD800-\\uDBFF][\\uDC00-\\uDFFF])/g;\n return e && e >= 0 ? t.substring(e - 2, e).match(i) ? (o = t.substr(0, e - 2) + t.substr(e), n && this.updateCaretPos(2, !0)) : (o = t.substr(0, e - 1) + t.substr(e), n && this.updateCaretPos(1, !0)) : t.slice(-2).match(i) ? (o = t.slice(0, -2), n && this.updateCaretPos(2, !0)) : (o = t.slice(0, -1), n && this.updateCaretPos(1, !0)), o;\n }\n }, {\n key: \"handleMaxLength\",\n value: function value(t, e) {\n var n = this.getOptions(),\n o = n.maxLength,\n i = t[n.inputName],\n s = e.length - 1 >= o;\n if (e.length <= i.length) return !1;\n if (Number.isInteger(o)) return n.debug && console.log(\"maxLength (num) reached:\", s), s ? (this.maxLengthReached = !0, !0) : (this.maxLengthReached = !1, !1);\n\n if (\"object\" === _typeof(o)) {\n var a = i.length === o[n.inputName];\n return n.debug && console.log(\"maxLength (obj) reached:\", a), a ? (this.maxLengthReached = !0, !0) : (this.maxLengthReached = !1, !1);\n }\n }\n }, {\n key: \"isMaxLengthReached\",\n value: function value() {\n return Boolean(this.maxLengthReached);\n }\n }, {\n key: \"isTouchDevice\",\n value: function value() {\n return \"ontouchstart\" in window || navigator.maxTouchPoints;\n }\n }, {\n key: \"pointerEventsSupported\",\n value: function value() {\n return window.PointerEvent;\n }\n }, {\n key: \"camelCase\",\n value: function value(t) {\n return !!t && t.toLowerCase().trim().split(/[.\\-_\\s]/g).reduce(function (t, e) {\n return e.length ? t + e[0].toUpperCase() + e.slice(1) : t;\n });\n }\n }]) && _defineProperties(t.prototype, e), n && _defineProperties(t, n), Utilities;\n }();\n\n function PhysicalKeyboard_defineProperties(t, e) {\n for (var n = 0; n < e.length; n++) {\n var o = e[n];\n o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(t, o.key, o);\n }\n }\n\n var i = function () {\n function PhysicalKeyboard(t) {\n var e = t.dispatch,\n n = t.getOptions;\n !function (t, e) {\n if (!(t instanceof e)) throw new TypeError(\"Cannot call a class as a function\");\n }(this, PhysicalKeyboard), this.dispatch = e, this.getOptions = n, o.bindMethods(PhysicalKeyboard, this);\n }\n\n var t, e, n;\n return t = PhysicalKeyboard, (e = [{\n key: \"handleHighlightKeyDown\",\n value: function value(t) {\n var e = this.getOptions(),\n n = this.getSimpleKeyboardLayoutKey(t);\n this.dispatch(function (t) {\n var o = t.getButtonElement(n) || t.getButtonElement(\"{\".concat(n, \"}\"));\n o && (o.style.backgroundColor = e.physicalKeyboardHighlightBgColor || \"#9ab4d0\", o.style.color = e.physicalKeyboardHighlightTextColor || \"white\");\n });\n }\n }, {\n key: \"handleHighlightKeyUp\",\n value: function value(t) {\n var e = this.getSimpleKeyboardLayoutKey(t);\n this.dispatch(function (t) {\n var n = t.getButtonElement(e) || t.getButtonElement(\"{\".concat(e, \"}\"));\n n && n.removeAttribute && n.removeAttribute(\"style\");\n });\n }\n }, {\n key: \"getSimpleKeyboardLayoutKey\",\n value: function value(t) {\n var e;\n return ((e = t.code.includes(\"Numpad\") || t.code.includes(\"Shift\") || t.code.includes(\"Space\") || t.code.includes(\"Backspace\") || t.code.includes(\"Control\") || t.code.includes(\"Alt\") || t.code.includes(\"Meta\") ? t.code : t.key) !== e.toUpperCase() || \"F\" === t.code[0] && Number.isInteger(Number(t.code[1])) && t.code.length <= 3) && (e = e.toLowerCase()), e;\n }\n }]) && PhysicalKeyboard_defineProperties(t.prototype, e), n && PhysicalKeyboard_defineProperties(t, n), PhysicalKeyboard;\n }();\n\n function _toConsumableArray(t) {\n return function (t) {\n if (Array.isArray(t)) {\n for (var e = 0, n = new Array(t.length); e < t.length; e++) {\n n[e] = t[e];\n }\n\n return n;\n }\n }(t) || function (t) {\n if (Symbol.iterator in Object(t) || \"[object Arguments]\" === Object.prototype.toString.call(t)) return Array.from(t);\n }(t) || function () {\n throw new TypeError(\"Invalid attempt to spread non-iterable instance\");\n }();\n }\n\n function Keyboard_classCallCheck(t, e) {\n if (!(t instanceof e)) throw new TypeError(\"Cannot call a class as a function\");\n }\n\n function Keyboard_defineProperties(t, e) {\n for (var n = 0; n < e.length; n++) {\n var o = e[n];\n o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(t, o.key, o);\n }\n }\n\n function _defineProperty(t, e, n) {\n return e in t ? Object.defineProperty(t, e, {\n value: n,\n enumerable: !0,\n configurable: !0,\n writable: !0\n }) : t[e] = n, t;\n }\n\n var s = function () {\n function SimpleKeyboard() {\n var t = this;\n Keyboard_classCallCheck(this, SimpleKeyboard), _defineProperty(this, \"handleParams\", function (t) {\n var e, n, o;\n if (\"string\" === typeof t[0]) e = t[0].split(\".\").join(\"\"), n = document.querySelector(\".\".concat(e)), o = t[1];else if (t[0] instanceof HTMLDivElement) {\n if (!t[0].className) throw console.warn(\"Any DOM element passed as parameter must have a class.\"), new Error(\"KEYBOARD_DOM_CLASS_ERROR\");\n e = t[0].className.split(\" \")[0], n = t[0], o = t[1];\n } else e = \"simple-keyboard\", n = document.querySelector(\".\".concat(e)), o = t[0];\n return {\n keyboardDOMClass: e,\n keyboardDOM: n,\n options: o\n };\n }), _defineProperty(this, \"getOptions\", function () {\n return t.options;\n }), _defineProperty(this, \"getCaretPosition\", function () {\n return t.caretPosition;\n }), _defineProperty(this, \"registerModule\", function (e, n) {\n t.modules[e] || (t.modules[e] = {}), n(t.modules[e]);\n }), _defineProperty(this, \"getKeyboardClassString\", function () {\n for (var e = arguments.length, n = new Array(e), o = 0; o < e; o++) {\n n[o] = arguments[o];\n }\n\n var i = [t.keyboardDOMClass].concat(n).filter(function (t) {\n return !!t;\n });\n return i.join(\" \");\n });\n\n for (var e = arguments.length, n = new Array(e), s = 0; s < e; s++) {\n n[s] = arguments[s];\n }\n\n var a = this.handleParams(n),\n r = a.keyboardDOMClass,\n u = a.keyboardDOM,\n c = a.options,\n l = void 0 === c ? {} : c;\n if (this.utilities = new o({\n getOptions: this.getOptions,\n getCaretPosition: this.getCaretPosition,\n dispatch: this.dispatch\n }), this.caretPosition = null, this.keyboardDOM = u, this.options = l, this.options.layoutName = this.options.layoutName || \"default\", this.options.theme = this.options.theme || \"hg-theme-default\", this.options.inputName = this.options.inputName || \"default\", this.options.preventMouseDownDefault = this.options.preventMouseDownDefault || !1, this.keyboardPluginClasses = \"\", o.bindMethods(SimpleKeyboard, this), this.input = {}, this.input[this.options.inputName] = \"\", this.keyboardDOMClass = r, this.buttonElements = {}, window.SimpleKeyboardInstances || (window.SimpleKeyboardInstances = {}), this.currentInstanceName = this.utilities.camelCase(this.keyboardDOMClass), window.SimpleKeyboardInstances[this.currentInstanceName] = this, this.allKeyboardInstances = window.SimpleKeyboardInstances, this.keyboardInstanceNames = Object.keys(window.SimpleKeyboardInstances), this.isFirstKeyboardInstance = this.keyboardInstanceNames[0] === this.currentInstanceName, this.physicalKeyboard = new i({\n dispatch: this.dispatch,\n getOptions: this.getOptions\n }), !this.keyboardDOM) throw console.warn('\".'.concat(r, '\" was not found in the DOM.')), new Error(\"KEYBOARD_DOM_ERROR\");\n this.render(), this.modules = {}, this.loadModules();\n }\n\n var t, e, n;\n return t = SimpleKeyboard, (e = [{\n key: \"handleButtonClicked\",\n value: function value(t) {\n var e = this.options.debug;\n if (\"{//}\" === t) return !1;\n \"function\" === typeof this.options.onKeyPress && this.options.onKeyPress(t), this.input[this.options.inputName] || (this.input[this.options.inputName] = \"\");\n var n = this.utilities.getUpdatedInput(t, this.input[this.options.inputName], this.caretPosition);\n\n if (this.input[this.options.inputName] !== n && (!this.options.inputPattern || this.options.inputPattern && this.inputPatternIsValid(n))) {\n if (this.options.maxLength && this.utilities.handleMaxLength(this.input, n)) return !1;\n this.input[this.options.inputName] = this.utilities.getUpdatedInput(t, this.input[this.options.inputName], this.caretPosition, !0), e && console.log(\"Input changed:\", this.input), this.options.syncInstanceInputs && this.syncInstanceInputs(), \"function\" === typeof this.options.onChange && this.options.onChange(this.input[this.options.inputName]), \"function\" === typeof this.options.onChangeAll && this.options.onChangeAll(this.input);\n }\n\n e && console.log(\"Key pressed:\", t);\n }\n }, {\n key: \"handleButtonMouseDown\",\n value: function value(t, e) {\n var n = this;\n this.options.preventMouseDownDefault && e.preventDefault(), this.options.stopMouseDownPropagation && e.stopPropagation(), e && e.target.classList.add(this.activeButtonClass), this.isMouseHold = !0, this.holdInteractionTimeout && clearTimeout(this.holdInteractionTimeout), this.holdTimeout && clearTimeout(this.holdTimeout), this.options.disableButtonHold || (this.holdTimeout = setTimeout(function () {\n !n.isMouseHold || (t.includes(\"{\") || t.includes(\"}\")) && \"{delete}\" !== t && \"{backspace}\" !== t && \"{bksp}\" !== t && \"{space}\" !== t && \"{tab}\" !== t || (n.options.debug && console.log(\"Button held:\", t), n.handleButtonHold(t, e)), clearTimeout(n.holdTimeout);\n }, 500));\n }\n }, {\n key: \"handleButtonMouseUp\",\n value: function value(t) {\n var e = this;\n this.recurseButtons(function (t) {\n t.classList.remove(e.activeButtonClass);\n }), this.isMouseHold = !1, this.holdInteractionTimeout && clearTimeout(this.holdInteractionTimeout), t && \"function\" === typeof this.options.onKeyReleased && this.options.onKeyReleased(t);\n }\n }, {\n key: \"handleKeyboardContainerMouseDown\",\n value: function value(t) {\n this.options.preventMouseDownDefault && t.preventDefault();\n }\n }, {\n key: \"handleButtonHold\",\n value: function value(t) {\n var e = this;\n this.holdInteractionTimeout && clearTimeout(this.holdInteractionTimeout), this.holdInteractionTimeout = setTimeout(function () {\n e.isMouseHold ? (e.handleButtonClicked(t), e.handleButtonHold(t)) : clearTimeout(e.holdInteractionTimeout);\n }, 100);\n }\n }, {\n key: \"syncInstanceInputs\",\n value: function value() {\n var t = this;\n this.dispatch(function (e) {\n e.replaceInput(t.input), e.caretPosition = t.caretPosition;\n });\n }\n }, {\n key: \"clearInput\",\n value: function value(t) {\n t = t || this.options.inputName, this.input[t] = \"\", this.caretPosition = 0, this.options.syncInstanceInputs && this.syncInstanceInputs();\n }\n }, {\n key: \"getInput\",\n value: function value(t) {\n return t = t || this.options.inputName, this.options.syncInstanceInputs && this.syncInstanceInputs(), this.input[t];\n }\n }, {\n key: \"setInput\",\n value: function value(t, e) {\n e = e || this.options.inputName, this.input[e] = t, this.options.syncInstanceInputs && this.syncInstanceInputs();\n }\n }, {\n key: \"replaceInput\",\n value: function value(t) {\n this.input = t;\n }\n }, {\n key: \"setOptions\",\n value: function value(t) {\n t = t || {}, this.options = Object.assign(this.options, t), this.onSetOptions(t), this.render();\n }\n }, {\n key: \"onSetOptions\",\n value: function value(t) {\n t.inputName && (this.options.debug && console.log(\"inputName changed. caretPosition reset.\"), this.caretPosition = null);\n }\n }, {\n key: \"clear\",\n value: function value() {\n this.keyboardDOM.innerHTML = \"\", this.keyboardDOM.className = this.keyboardDOMClass, this.buttonElements = {};\n }\n }, {\n key: \"dispatch\",\n value: function value(t) {\n if (!window.SimpleKeyboardInstances) throw console.warn(\"SimpleKeyboardInstances is not defined. Dispatch cannot be called.\"), new Error(\"INSTANCES_VAR_ERROR\");\n return Object.keys(window.SimpleKeyboardInstances).forEach(function (e) {\n t(window.SimpleKeyboardInstances[e], e);\n });\n }\n }, {\n key: \"addButtonTheme\",\n value: function value(t, e) {\n var n = this;\n if (!e || !t) return !1;\n t.split(\" \").forEach(function (o) {\n e.split(\" \").forEach(function (e) {\n n.options.buttonTheme || (n.options.buttonTheme = []);\n var i = !1;\n n.options.buttonTheme.map(function (t) {\n if (t.class.split(\" \").includes(e)) {\n i = !0;\n var n = t.buttons.split(\" \");\n n.includes(o) || (i = !0, n.push(o), t.buttons = n.join(\" \"));\n }\n\n return t;\n }), i || n.options.buttonTheme.push({\n class: e,\n buttons: t\n });\n });\n }), this.render();\n }\n }, {\n key: \"removeButtonTheme\",\n value: function value(t, e) {\n var n = this;\n if (!t && !e) return this.options.buttonTheme = [], this.render(), !1;\n t && Array.isArray(this.options.buttonTheme) && this.options.buttonTheme.length && (t.split(\" \").forEach(function (t) {\n n.options.buttonTheme.map(function (o, i) {\n if (e && e.includes(o.class) || !e) {\n var s = o.buttons.split(\" \").filter(function (e) {\n return e !== t;\n });\n s.length ? o.buttons = s.join(\" \") : (n.options.buttonTheme.splice(i, 1), o = null);\n }\n\n return o;\n });\n }), this.render());\n }\n }, {\n key: \"getButtonElement\",\n value: function value(t) {\n var e,\n n = this.buttonElements[t];\n return n && (e = n.length > 1 ? n : n[0]), e;\n }\n }, {\n key: \"inputPatternIsValid\",\n value: function value(t) {\n var e,\n n = this.options.inputPattern;\n\n if ((e = n instanceof RegExp ? n : n[this.options.inputName]) && t) {\n var o = e.test(t);\n return this.options.debug && console.log('inputPattern (\"'.concat(e, '\"): ').concat(o ? \"passed\" : \"did not pass!\")), o;\n }\n\n return !0;\n }\n }, {\n key: \"setEventListeners\",\n value: function value() {\n !this.isFirstKeyboardInstance && this.allKeyboardInstances || (this.options.debug && console.log(\"Caret handling started (\".concat(this.keyboardDOMClass, \")\")), document.addEventListener(\"keyup\", this.handleKeyUp), document.addEventListener(\"keydown\", this.handleKeyDown), document.addEventListener(\"mouseup\", this.handleMouseUp), document.addEventListener(\"touchend\", this.handleTouchEnd));\n }\n }, {\n key: \"handleKeyUp\",\n value: function value(t) {\n this.caretEventHandler(t), this.options.physicalKeyboardHighlight && this.physicalKeyboard.handleHighlightKeyUp(t);\n }\n }, {\n key: \"handleKeyDown\",\n value: function value(t) {\n this.options.physicalKeyboardHighlight && this.physicalKeyboard.handleHighlightKeyDown(t);\n }\n }, {\n key: \"handleMouseUp\",\n value: function value(t) {\n this.caretEventHandler(t);\n }\n }, {\n key: \"handleTouchEnd\",\n value: function value(t) {\n this.caretEventHandler(t);\n }\n }, {\n key: \"caretEventHandler\",\n value: function value(t) {\n var e;\n t.target.tagName && (e = t.target.tagName.toLowerCase()), this.dispatch(function (n) {\n n.isMouseHold && (n.isMouseHold = !1), \"textarea\" !== e && \"input\" !== e || n.options.disableCaretPositioning ? n.options.disableCaretPositioning && (n.caretPosition = null) : (n.caretPosition = t.target.selectionStart, n.options.debug && console.log(\"Caret at: \", t.target.selectionStart, t.target.tagName.toLowerCase(), \"(\".concat(n.keyboardDOMClass, \")\")));\n });\n }\n }, {\n key: \"recurseButtons\",\n value: function value(t) {\n var e = this;\n if (!t) return !1;\n Object.keys(this.buttonElements).forEach(function (n) {\n return e.buttonElements[n].forEach(t);\n });\n }\n }, {\n key: \"destroy\",\n value: function value() {\n this.options.debug && console.log(\"Destroying simple-keyboard instance: \".concat(this.currentInstanceName)), document.removeEventListener(\"keyup\", this.handleKeyUp), document.removeEventListener(\"keydown\", this.handleKeyDown), document.removeEventListener(\"mouseup\", this.handleMouseUp), document.removeEventListener(\"touchend\", this.handleTouchEnd), document.onpointerup = null, document.ontouchend = null, document.ontouchcancel = null, document.onmouseup = null;\n\n var deleteButton = function deleteButton(t) {\n t.onpointerdown = null, t.onpointerup = null, t.onpointercancel = null, t.ontouchstart = null, t.ontouchend = null, t.ontouchcancel = null, t.onclick = null, t.onmousedown = null, t.onmouseup = null, t.remove(), t = null;\n };\n\n this.recurseButtons(deleteButton), this.recurseButtons = null, deleteButton = null, this.keyboardDOM.onpointerdown = null, this.keyboardDOM.ontouchstart = null, this.keyboardDOM.onmousedown = null, this.clear(), window.SimpleKeyboardInstances[this.currentInstanceName] = null, delete window.SimpleKeyboardInstances[this.currentInstanceName], this.initialized = !1;\n }\n }, {\n key: \"getButtonThemeClasses\",\n value: function value(t) {\n var e = this.options.buttonTheme,\n n = [];\n return Array.isArray(e) && e.forEach(function (e) {\n if (e.class && \"string\" === typeof e.class && e.buttons && \"string\" === typeof e.buttons) {\n var o = e.class.split(\" \");\n e.buttons.split(\" \").includes(t) && (n = [].concat(_toConsumableArray(n), _toConsumableArray(o)));\n } else console.warn('Incorrect \"buttonTheme\". Please check the documentation.', e);\n }), n;\n }\n }, {\n key: \"setDOMButtonAttributes\",\n value: function value(t, e) {\n var n = this.options.buttonAttributes;\n Array.isArray(n) && n.forEach(function (n) {\n n.attribute && \"string\" === typeof n.attribute && n.value && \"string\" === typeof n.value && n.buttons && \"string\" === typeof n.buttons ? n.buttons.split(\" \").includes(t) && e(n.attribute, n.value) : console.warn('Incorrect \"buttonAttributes\". Please check the documentation.', n);\n });\n }\n }, {\n key: \"onTouchDeviceDetected\",\n value: function value() {\n this.processAutoTouchEvents(), this.disableContextualWindow();\n }\n }, {\n key: \"disableContextualWindow\",\n value: function value() {\n window.oncontextmenu = function (t) {\n if (t.target.classList.contains(\"hg-button\")) return t.preventDefault(), t.stopPropagation(), !1;\n };\n }\n }, {\n key: \"processAutoTouchEvents\",\n value: function value() {\n this.options.autoUseTouchEvents && (this.options.useTouchEvents = !0, this.options.debug && console.log(\"autoUseTouchEvents: Touch device detected, useTouchEvents enabled.\"));\n }\n }, {\n key: \"onInit\",\n value: function value() {\n this.options.debug && console.log(\"\".concat(this.keyboardDOMClass, \" Initialized\")), this.setEventListeners(), \"function\" === typeof this.options.onInit && this.options.onInit();\n }\n }, {\n key: \"beforeFirstRender\",\n value: function value() {\n this.utilities.isTouchDevice() && this.onTouchDeviceDetected(), \"function\" === typeof this.options.beforeFirstRender && this.options.beforeFirstRender(), this.isFirstKeyboardInstance && this.utilities.pointerEventsSupported() && !this.options.useTouchEvents && !this.options.useMouseEvents && this.options.debug && console.log(\"Using PointerEvents as it is supported by this browser\"), this.options.useTouchEvents && this.options.debug && console.log(\"useTouchEvents has been enabled. Only touch events will be used.\");\n }\n }, {\n key: \"beforeRender\",\n value: function value() {\n \"function\" === typeof this.options.beforeRender && this.options.beforeRender();\n }\n }, {\n key: \"onRender\",\n value: function value() {\n \"function\" === typeof this.options.onRender && this.options.onRender();\n }\n }, {\n key: \"onModulesLoaded\",\n value: function value() {\n \"function\" === typeof this.options.onModulesLoaded && this.options.onModulesLoaded();\n }\n }, {\n key: \"loadModules\",\n value: function value() {\n var t = this;\n Array.isArray(this.options.modules) && (this.options.modules.forEach(function (e) {\n var n = new e();\n\n if (n.constructor.name && \"Function\" !== n.constructor.name) {\n var o = \"module-\".concat(t.utilities.camelCase(n.constructor.name));\n t.keyboardPluginClasses = t.keyboardPluginClasses + \" \".concat(o);\n }\n\n n.init(t);\n }), this.keyboardPluginClasses = this.keyboardPluginClasses + \" modules-loaded\", this.render(), this.onModulesLoaded());\n }\n }, {\n key: \"getModuleProp\",\n value: function value(t, e) {\n return !!this.modules[t] && this.modules[t][e];\n }\n }, {\n key: \"getModulesList\",\n value: function value() {\n return Object.keys(this.modules);\n }\n }, {\n key: \"parseRowDOMContainers\",\n value: function value(t, e, n, o) {\n var i = this,\n s = Array.from(t.children),\n a = 0;\n return s.length && n.forEach(function (n, r) {\n var u = o[r];\n if (!u || !(u > n)) return !1;\n var c = n - a,\n l = u - a,\n h = document.createElement(\"div\");\n h.className += \"hg-button-container\";\n var d = \"\".concat(i.options.layoutName, \"-r\").concat(e, \"c\").concat(r);\n h.setAttribute(\"data-skUID\", d);\n var p = s.splice(c, l - c + 1);\n a = l - c, p.forEach(function (t) {\n return h.appendChild(t);\n }), s.splice(c, 0, h), t.innerHTML = \"\", s.forEach(function (e) {\n return t.appendChild(e);\n }), i.options.debug && console.log(\"rowDOMContainer\", p, c, l, a + 1);\n }), t;\n }\n }, {\n key: \"render\",\n value: function value() {\n var t = this;\n this.clear(), this.initialized || this.beforeFirstRender(), this.beforeRender();\n var e = \"hg-layout-\".concat(this.options.layoutName),\n n = this.options.layout || {\n default: [\"` 1 2 3 4 5 6 7 8 9 0 - = {bksp}\", \"{tab} q w e r t y u i o p [ ] \\\\\", \"{lock} a s d f g h j k l ; ' {enter}\", \"{shift} z x c v b n m , . / {shift}\", \".com @ {space}\"],\n shift: [\"~ ! @ # $ % ^ & * ( ) _ + {bksp}\", \"{tab} Q W E R T Y U I O P { } |\", '{lock} A S D F G H J K L : \" {enter}', \"{shift} Z X C V B N M < > ? {shift}\", \".com @ {space}\"]\n },\n o = this.options.useTouchEvents || !1,\n i = o ? \"hg-touch-events\" : \"\",\n s = this.options.useMouseEvents || !1,\n a = this.options.disableRowButtonContainers;\n this.keyboardDOM.className = this.getKeyboardClassString(this.options.theme, e, this.keyboardPluginClasses, i), n[this.options.layoutName].forEach(function (e, n) {\n var i = e.split(\" \"),\n r = document.createElement(\"div\");\n r.className += \"hg-row\";\n var u = [],\n c = [];\n i.forEach(function (e, i) {\n var l,\n h = !a && e.includes(\"[\") && e.length > 1,\n d = !a && e.includes(\"]\") && e.length > 1;\n h && (u.push(i), e = e.replace(/\\[/g, \"\")), d && (c.push(i), e = e.replace(/\\]/g, \"\"));\n var p = t.utilities.getButtonClass(e),\n f = t.utilities.getButtonDisplayName(e, t.options.display, t.options.mergeDisplay),\n y = t.options.useButtonTag ? \"button\" : \"div\",\n b = document.createElement(y);\n b.className += \"hg-button \".concat(p), (l = b.classList).add.apply(l, _toConsumableArray(t.getButtonThemeClasses(e))), t.setDOMButtonAttributes(e, function (t, e) {\n b.setAttribute(t, e);\n }), t.activeButtonClass = \"hg-activeButton\", !t.utilities.pointerEventsSupported() || o || s ? o ? (b.ontouchstart = function (n) {\n t.handleButtonClicked(e), t.handleButtonMouseDown(e, n);\n }, b.ontouchend = function () {\n t.handleButtonMouseUp(e);\n }, b.ontouchcancel = function () {\n t.handleButtonMouseUp(e);\n }) : (b.onclick = function () {\n t.isMouseHold = !1, t.handleButtonClicked(e);\n }, b.onmousedown = function (n) {\n t.handleButtonMouseDown(e, n);\n }, b.onmouseup = function () {\n t.handleButtonMouseUp(e);\n }) : (b.onpointerdown = function (n) {\n t.handleButtonClicked(e), t.handleButtonMouseDown(e, n);\n }, b.onpointerup = function () {\n t.handleButtonMouseUp(e);\n }, b.onpointercancel = function () {\n t.handleButtonMouseUp(e);\n }), b.setAttribute(\"data-skBtn\", e);\n var m = \"\".concat(t.options.layoutName, \"-r\").concat(n, \"b\").concat(i);\n b.setAttribute(\"data-skBtnUID\", m);\n var g = document.createElement(\"span\");\n g.innerHTML = f, b.appendChild(g), t.buttonElements[e] || (t.buttonElements[e] = []), t.buttonElements[e].push(b), r.appendChild(b);\n }), r = t.parseRowDOMContainers(r, n, u, c), t.keyboardDOM.appendChild(r);\n }), this.onRender(), this.initialized || (this.initialized = !0, !this.utilities.pointerEventsSupported() || o || s ? o ? (document.ontouchend = function () {\n return t.handleButtonMouseUp();\n }, document.ontouchcancel = function () {\n return t.handleButtonMouseUp();\n }, this.keyboardDOM.ontouchstart = function (e) {\n return t.handleKeyboardContainerMouseDown(e);\n }) : o || (document.onmouseup = function () {\n return t.handleButtonMouseUp();\n }, this.keyboardDOM.onmousedown = function (e) {\n return t.handleKeyboardContainerMouseDown(e);\n }) : (document.onpointerup = function () {\n return t.handleButtonMouseUp();\n }, this.keyboardDOM.onpointerdown = function (e) {\n return t.handleKeyboardContainerMouseDown(e);\n }), this.onInit());\n }\n }]) && Keyboard_defineProperties(t.prototype, e), n && Keyboard_defineProperties(t, n), SimpleKeyboard;\n }();\n\n e.default = s;\n }]);\n});","module.exports = function (module) {\n if (!module.webpackPolyfill) {\n module.deprecate = function () {};\n\n module.paths = []; // module.parent = undefined by default\n\n if (!module.children) module.children = [];\n Object.defineProperty(module, \"loaded\", {\n enumerable: true,\n get: function get() {\n return module.l;\n }\n });\n Object.defineProperty(module, \"id\", {\n enumerable: true,\n get: function get() {\n return module.i;\n }\n });\n module.webpackPolyfill = 1;\n }\n\n return module;\n};","function _typeof(obj) {\n \"@babel/helpers - typeof\";\n\n if (typeof Symbol === \"function\" && typeof Symbol.iterator === \"symbol\") {\n module.exports = _typeof = function _typeof(obj) {\n return typeof obj;\n };\n } else {\n module.exports = _typeof = function _typeof(obj) {\n return obj && typeof Symbol === \"function\" && obj.constructor === Symbol && obj !== Symbol.prototype ? \"symbol\" : typeof obj;\n };\n }\n\n return _typeof(obj);\n}\n\nmodule.exports = _typeof;","export const parseProps = props => ({\r\n ...props,\r\n theme: `simple-keyboard ${props.theme || \"hg-theme-default\"}`\r\n});\r\n\r\nexport const propsChanged = (prevProps, props) => {\r\n const cleanProps = sourceObj =>\r\n JSON.stringify({\r\n ...sourceObj,\r\n stateToIgnore: null\r\n });\r\n\r\n return cleanProps(props) !== cleanProps(prevProps);\r\n};\r\n","import React, { useEffect, useRef } from \"react\";\r\nimport Keyboard from \"simple-keyboard\";\r\nimport { parseProps, propsChanged } from \"../services/Utilities\";\r\nimport \"simple-keyboard/build/css/index.css\";\r\n\r\nconst KeyboardReact = props => {\r\n const cssClass = props.baseClass || \"react-simple-keyboard\";\r\n const initRef = useRef();\r\n const keyboardRef = useRef();\r\n const previousProps = useRef(props);\r\n\r\n useEffect(() => {\r\n /**\r\n * Initialize simple-keyboard\r\n */\r\n if (!initRef.current) {\r\n initRef.current = true;\r\n props.debug && console.log(\"ReactSimpleKeyboard: Init\");\r\n keyboardRef.current = new Keyboard(`.${cssClass}`, parseProps(props));\r\n props.keyboardRef && props.keyboardRef(keyboardRef.current);\r\n }\r\n\r\n /**\r\n * Only trigger render if props changed\r\n */\r\n if (propsChanged(previousProps.current, props)) {\r\n let keyboard = keyboardRef.current;\r\n previousProps.current = props;\r\n keyboard.setOptions(parseProps(props));\r\n props.debug && console.log(\"ReactSimpleKeyboard: Rendered\");\r\n }\r\n }, [initRef, cssClass, previousProps, props]);\r\n\r\n return
;\r\n};\r\n\r\nexport default KeyboardReact;\r\n","import Keyboard from \"./components/Keyboard\";\r\n\r\nexport default Keyboard;\r\n"],"sourceRoot":""} \ No newline at end of file diff --git a/package-lock.json b/package-lock.json index 43c730f16..76f7ee19e 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,6 +1,6 @@ { "name": "react-simple-keyboard", - "version": "2.1.117", + "version": "2.2.0", "lockfileVersion": 1, "requires": true, "dependencies": { @@ -24616,9 +24616,9 @@ "dev": true }, "simple-keyboard": { - "version": "2.27.86", - "resolved": "https://registry.npmjs.org/simple-keyboard/-/simple-keyboard-2.27.86.tgz", - "integrity": "sha512-B5hMYBjN+ZGa2EnZD5ViiI1iAiPXMjTG9/HMJVnDc1I37GFcc9SYsmYU+27fLjmplsTWAswjafg4llgN4HRkSw==", + "version": "2.28.2", + "resolved": "https://registry.npmjs.org/simple-keyboard/-/simple-keyboard-2.28.2.tgz", + "integrity": "sha512-Bl0zgKFjGdGcswILVGs4Z3rcYwDJ3GhOc8IcELG0JTlL3102SOKXKLB3a9cFdcU77MmMegbN4L5l1vG51tQc2g==", "dev": true }, "simple-swizzle": { diff --git a/package.json b/package.json index d16692727..2ca6b012d 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "react-simple-keyboard", - "version": "2.1.117", + "version": "2.2.0", "description": "React.js Virtual Keyboard", "main": "build/index.js", "types": "build/index.d.ts", @@ -96,7 +96,7 @@ "resolve-url-loader": "3.1.1", "sass-loader": "8.0.2", "semver": "7.1.2", - "simple-keyboard": "^2.27.86", + "simple-keyboard": "^2.28.2", "style-loader": "1.1.3", "terser-webpack-plugin": "2.3.4", "ts-pnp": "1.1.5",