zh-cangjie
- Convert strings to/from cangjie chars (人弓火 -> ONF || ONF -> 人弓火)
- Convert chinese characters to/from cangjie (雨 -> 一中月卜 || MLBY -> 雨).
Created for zhdict.net
Usage
var cangjie = ; // Convert alpha string into cangjie characterscangjie// "一土戈中土" // Convert cangjie string into alphacangjie// "MGILG" /* * From v0.2.0 */// Get the cangjie equivalent of a given characterlet found = await cangjie;// - OR -cangjie; // Search for characters based on cangjie string// Sometimes this will return multiple characterslet found = await cangjie;// - OR -cangjie; let found = await cangjie;// - OR -cangjie; let found = await cangjie;// - OR -cangjie; // Search for characters whos cangjie equivalent begins with the given string// This could be used, for example, in a character prediction widget for// a soft cangjie keyboardlet found = await cangjie;cangjie;
Changes
4 December 2018 - 0.2.0
.findCharacters()
replaces.search()
and.findCharacter()
findCharacters()
andfromCharacter()
areawait
-ableRequires Node.js 8+ (async/await)
9 September 2016 - 0.1.0
- Added ability to lookup cangjie for a given Chinese character (based on data from Unihan/Unicode Character Database
- Added ability to search for characters based on a full or partial cangjie string (as either [A-Z]+ or cangjie 'radicals')
23 August 2015 - 0.0.2
Initial release
TODO
- Potentially paginate results returned by
search()
findCharacters()
Notes
This is currently under development. API may/likely will grow and change.
Character <-> cangjie data was compiled from the Unicode Character Database.
Unicode Character Database
Copyright © 1991-2016 Unicode, Inc. All rights reserved.
Distributed under the Terms of Use in http://www.unicode.org/copyright.html.