JS Based on-screen keyboard for browser, like on cellphones and tablets

后端 未结 3 1911
太阳男子
太阳男子 2020-12-08 23:04

We have an app for an embedded system, and we are developing several apps based on HTML5, CSS3, and some JS libraries, which run on a webkit browser. I was wondering if ther

3条回答
  •  夕颜
    夕颜 (楼主)
    2020-12-08 23:55

    You could try the Virtual Keyboard which has a lot of features, language layouts and is very well documented.
    You can also easily integrate it with bootstrap:

    $('#keyboard').keyboard({
        layout: 'qwerty',
        css: {
            // input & preview
            input: 'form-control input-sm',
            // keyboard container
            container: 'center-block dropdown-menu', // jumbotron
            // default state
            buttonDefault: 'btn btn-default',
            // hovered button
            buttonHover: 'btn-primary',
            // Action keys (e.g. Accept, Cancel, Tab, etc);
            // this replaces "actionClass" option
            buttonAction: 'active',
            // used when disabling the decimal button {dec}
            // when a decimal exists in the input area
            buttonDisabled: 'disabled'
        }
    })
    

    Find the full example here.

    You could also try the On Screen Keyboard which is a lot simpler and less feature rich.

提交回复
热议问题