All notable changes to this project will be documented in this file.
The format is based on Keep a Changelog and this project adheres to Semantic Versioning.
bind()
was ignoring useObsoleteKana & customKanaMapping optionsku
not converting immediately withIMEMode
- Unpkg should now properly source the correct module for use in the browser as a script tag
- When a custom mapping was provided in options and then a different one was given, we only replaced the mapping with the new one when a previous one did not exist. Now we will always replace the custom mapping when it changes. WaniKani#132
- Support for converting some k-- constructions. WaniKani#126
- Allow user to ignore converting long vowel mark in toHiragana. WaniKani#128
- The UMD build now only includes polyfills for browserslist defaults (> 0.5%, last 2 versions, Firefox ESR, not dead - at time of writing) which drops support for IE.
- Node support is now 12+ (though likely would continue to work fine on older versions)
4.0.2 - 2018-04-30
- react-native field in lib package.json
- corrected recent dates in changelog (2017 -> 2018)
4.0.1 - 2018-04-30
- stripOkurigana(): If the input has the same kana at different locations, such as '申し申し', the inner kana was stripped instead
4.0.0 - 2018-04-26
- stripOkurigana() options are now
{ leading: Boolean, matchKanji: String }
- stripOkurigana() "all" option has been removed but can be easily reproduced via
[...text].filter(isKana)
3.1.1 - 2018-03-26
- some versions of Android GBoard English keyboard entering 'n' followed by a consonant would block further conversion
3.1.0 - 2018-03-01
- bind() now sets necessary attributes automatically (autocomplete, spellcheck etc)
- toKana() no longer converts zenkaku latin toKana now: ('imi imi' => 'imi いみ')
- toRomaji() extends vowels for katakana chōonpu, IE: ゲーム => geemu, toHiragana() converts to hyphen => ge-mu
- toKana() without IME mode converts lone 'n' => 'ん', 'nn' => 'んん' if no other chars present
- isJapanese() now returns false for latin numbers (201) (still true for zenkaku 201)
- tokenize() splits into finer categories, view API documentation and tests for full details
- rewrite of conversion methods to allow custom mapping adapters
- isJapanese and isRomaji now accept a second param, a regexp that will also pass the check
- global option romanization for toRomaji() (currently only 'hepburn' however)
- global option customKanaMapping for toKana()
- global option customRomajiMapping for toRomaji()
- inserting text between already existing characters in a bind() IME input field now properly sets cursor to correct position after conversion
- toRomaji() little ヶヵ used in words like 一ヶ月 are no longer converted since they are used as symbols (like the kanji) and do not actually denote kana. Previous behaviour: 一ヶ月 => 一 ke 月
- toRomaji() no longer incorrectly duplicates non-glottal stops following っ. Previous behaviour: あっ、 -> a,,
2.3.4 - 2017-12-16
- Uppercase input with toHiragana() including a double consonant was incorrectly producing a katakana ッ instead of っ
2.3.3 - 2017-12-12
- Add https to unpkg link
2.3.2 - 2017-12-12
- Specify minified bundle in package.json for easy use with unpkg
2.3.1 - 2017-10-17
- Set cursor in IME mode to the current position after conversion (rather than the end of all input)
2.3.0 - 2017-08-28
- Increase character coverage for isJapanese to include numbers and hankaku katakana
2.2.4 - 2017-08-24
- Pass through long vowel conversion using toHiragana with odd/mixed input
2.2.3 - 2017-08-05
- Mobile input not converting automatically during autosuggest (regression due to 2.2.1)
2.2.2 - 2017-07-30
- Keep track of event listeners by generated ids
2.2.1 - 2017-07-30
2.2.0 - 2017-07-13
- Options object setting
IMEMode
can now accept'toHiragana'
or'toKatakana'
to enforce specific conversion on input
2.1.0 - 2017-07-09
- Set
autocapitalize="none"
on bound input fields - Handle multiple event listeners with separate options
- Increased test coverage
- Hold onto merged options for dom utils via closure instead of global
- Keep track of event listeners for removal on unbind
bind
,unbind
are now named exports in 'wanakana/domUtils'
2.0.4 - 2017-07-07
- Wanakana website address in package.json
2.0.3 - 2017-07-07
- Missing description field in package.json
2.0.2 - 2017-06-30
- Documentation regarding recommended use of autocapitalize="none" on input fields
- Improve font readability on demo page
2.0.1 - 2017-06-17
- Fixed some incorrect text references
- Internal build modifications
2.0.0 - 2017-06-17
- Changelog!
- Separate bundles for different environments (node, esmodules, browser)
- New method:
stripOkurigana()
- New method:
tokenize()
- Default options extended with
passRomaji
andupcaseKatakana
- Extended docs
- Ambiguous N thanks to @DTJB
- Mixed Case toHiragana thanks to @DTJB
- Katakana Long Vowels thanks to @dianahervascastillo @maesierra @codebar @ladieswhocode
- Missing Space thanks to @mimshwright
- Transliteration converts major punctuation marks both ways.
isJapanese()
&isRomaji()
check major punctuation.isRomaji()
allows hepburn romanisation long vowels. (IE. Tōkyō)