Virtual Keyboard for Angular applications
$ npm install --save popup-keyboard
Add NgVirtualKeyboardModule
as an import in your app's root NgModule.
import { NgVirtualKeyboardModule } from 'popup-keyboard';
@NgModule({
...
imports: [
...
NgVirtualKeyboardModule,
],
...
})
export class AppModule { }
Simple usage example
<input type="text" value=""
popup-keyboard
popup-keyboard-layout="alphanumeric"
popup-keyboard-placeholder="Custom placeholder text"
/>
Instead of opening the dialog you can use it as an onscreen keyboard
<input type="number" [(ngModel)]="text" #inputField/>
<virtual-keyboard layout="numeric" [inputRef]="inputField"></virtual-keyboard>
Attribute | Description |
---|---|
popup-keyboard |
Required to initialize Virtual Keyboard to specified input |
popup-keyboard-layout |
Used layout on keyboard, following keyboards are defaults that you can use alphanumeric, alphanumericNordic, extended, extendedNordic, numeric, phone |
popup-keyboard-placeholder |
Override placeholder text, if input has not any - or you want to override input placeholder value |
https://protacon.github.io/popup-keyboard/
Copyright (c) 2017 Protacon