Skip to content

Commit

Permalink
Fixed Shift_JIS table
Browse files Browse the repository at this point in the history
  • Loading branch information
receiptline committed Mar 30, 2024
1 parent 8544c7c commit bfd7c65
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
# Changelog

## [1.0.4] - 2024-03-30
### Fixed
- Shift_JIS table

## [1.0.3] - 2024-03-29
### Fixed
- README
Expand Down
2 changes: 1 addition & 1 deletion lib/receipt-printer.js
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ const ReceiptPrinter = (() => {
//
const iconv = (() => {
// shiftjis table
const sjistable = { '\u00a5': 0x5c, '\u203e': 0x7e };
const sjistable = { '\u00a5': 0x5c, '\u203e': 0x7e, '\u301c': 0x8160 };
const sjisdecoder = new TextDecoder('shift-jis');
for (let i = 0x81; i <= 0xfc; i++) {
if (i <= 0x84 || i >= 0x87 && i <= 0x9f || i >= 0xe0 && i <= 0xea || i >= 0xed && i <= 0xee || i >= 0xfa) {
Expand Down

0 comments on commit bfd7c65

Please sign in to comment.