https://github.com/ndaidong/vnikey
Util that enables Vietnamese number key based for web browsers
https://github.com/ndaidong/vnikey
Last synced: 4 days ago
JSON representation
Util that enables Vietnamese number key based for web browsers
- Host: GitHub
- URL: https://github.com/ndaidong/vnikey
- Owner: ndaidong
- License: mit
- Created: 2020-05-30T17:00:47.000Z (about 5 years ago)
- Default Branch: main
- Last Pushed: 2024-05-08T02:02:16.000Z (about 1 year ago)
- Last Synced: 2025-05-30T15:12:31.843Z (20 days ago)
- Language: JavaScript
- Homepage: https://ndaidong.github.io/vnikey
- Size: 223 KB
- Stars: 1
- Watchers: 0
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# vnikey
Small JavaScript library for typing Vietnamese diacritical marks in the web browsers.
[](https://badge.fury.io/js/vnikey)
[](https://travis-ci.org/ndaidong/vnikey)
[](https://coveralls.io/github/ndaidong/vnikey?branch=master)### About `vnikey`
`vnikey` is a tool for typing Vietnamese, similar to other libraries as HIM, VIM, Mudim, etc. However `vnikey` supports only VNI type mode (aka "Vietnamese number key based"). Personally I appreciate the intelligence and elegance of the VNI typing method. It's great to type English terms mixed with Vietnamese. But if you are already using TELEX or VIQR, then `vnikey` is not for you.
`vnikey` also doesn't not provide the further features like auto-correct spelling errors. There is the better tools for that.
`vnikey` focuses on the main purpose: easy to type Vietnamese as long as English. It tries to avoid to place accent marks when you type something looks like English.
### About VNI typing method
Basically VNI method uses the number keys from 1 to 9 to add diacritical marks to the words and letters, in which the keys 1, 2, 3, 4, 5 used for tone marks, the keys 6, 7, 8 for vowel marks, and the key 9 for crossed D/d (dyet).
| Keys | 1 ! | 2 @ | 3 # | 4 $ | 5 % | 6 ^ | 7 & | 8 * | 9 ( |
|--|--|--|--|--|--|--|--|--|--|
| Meaning | acute | grave | hook | tilde | underdot | circumflex | horn | breve | dyet
| Examples | á, é... | à, è... | ả, ẻ... | á, é... | ạ, ẹ... | â, ê... | ơ, ư | ă | đ, Đ |Thus, to get "Chào Việt Nam", we type "Chao2 Vie6t5 Nam".
### Demo
- https://ndaidong.github.io/vnikey
## Embed `vnikey` into the web pages
- CDN
- [vnikey.js](https://cdn.jsdelivr.net/npm/vnikey@latest)
- NPM
```
npm i vnikey
```And then:
```js
import 'vnikey'
```## Extensions for web browsers
### Webkit based browsers (Chrome, Vivaldi, Chomium, Opera, etc)
- [vnikey for Webkit](https://chrome.google.com/webstore/detail/gipmmnagikfceadakmonbllelfjcmbam)
### Gecko based browsers (Firefox, SeaMonkey, etc)
- [vnikey for Gecko](https://addons.mozilla.org/en-US/firefox/addon/vnikey-for-gecko/)
# Test
```
git clone https://github.com/ndaidong/vnikey.git
cd vnikey
npm install
npm test
```# License
The MIT License (MIT)