Socket
Socket
Sign inDemoInstall

react-virtual-keyboard-js

Package Overview
Dependencies
3
Maintainers
1
Versions
2
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    react-virtual-keyboard-js

Virtual keyboard for react apps


Version published
Weekly downloads
0
decreased by-100%
Maintainers
1
Created
Weekly downloads
 

Readme

Source
Swash Logo
React Virtual Keyboard

Virtual Keyboard

React Virtual Keyboard is a small library for react developers who they need a customizable virtual keyboard for their applications.

Issues & Questions

For reporting issues or asking questions please use the github issues or contact skarimi68@gmail.com.

Getting Started

You can simply add this library to your react application using npm or yarn.

npm install react-virtual-keyboard-js

yarn add react-virtual-keyboard-js

How to use

After installing library, you can use VirtualKeyboard component in your application same as below:

import { VirtualKeyboard } from 'react-virtual-keyboard-js';

...
      <VirtualKeyboard
        className="virtualKeyboard"
        value={text}
        onChange={setText}
        shuffleOn={["charkey", "start"]}
        buttonProps={{
          className: "btn",
          activeClassName: "activeBtn",
        }}
        gap="10px"
      />
    </div>

Props

PropOptionsDescription
classNameOptional, stringCSS class name to change keyboard pan
valueRequired, stringState value of keyboard
onChangeRequired, Function (value: string) => voidonChange method
shuffleOnOptional, Array of start, charkey, space, clear, tab, backspace, keyIf this array includes one of these options, character keys will be shuffled on that event. for example start option shuffles keys on mount, tab option shuffles keys when tab key is pressed and key option shuffles them on each button.
buttonPropsOptional, Object containing className and activeClassNameYou can customize buttons based on your need using className. and add another style to shift button when it is pressed using activeClassName
gapOptional, string or numberThis prop let you change the gap among buttons
charKeysArray of { c: string, s: string} You will be able to change character keys of keyboard by providing an array of c as character and s as corresponding character which will be shown when shift is pressed. For example you can make Greek keyboard by providing an array of Greek alphabets

Keywords

FAQs

Last updated on 09 Jun 2023

Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc