Skip to content

Commit ccbde08

Browse files
committed
feat(device): add grundig sonicmic 3 device
1 parent d0d5d28 commit ccbde08

File tree

5 files changed

+32
-3
lines changed

5 files changed

+32
-3
lines changed

.husky/pre-commit

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
#!/usr/bin/env sh
2+
. "$(dirname -- "$0")/_/husky.sh"
3+
4+
npm run lint
5+
npm run formatCheck
6+
npm test

package-lock.json

Lines changed: 22 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
"lint": "eslint --ignore-path .gitignore --ext .ts .",
88
"format": "git clang-format",
99
"formatCheck": "git clang-format --diff",
10-
"prepare": "npm run build",
10+
"prepare": "husky install",
1111
"test": "karma start karma.unit.js"
1212
},
1313
"author": "[email protected]",
@@ -35,6 +35,7 @@
3535
"eslint-plugin-n": "^15.2.5",
3636
"eslint-plugin-promise": "^6.0.1",
3737
"html-webpack-plugin": "^5.5.0",
38+
"husky": "^8.0.1",
3839
"jasmine": "^4.3.0",
3940
"karma": "^6.4.0",
4041
"karma-chrome-launcher": "^3.1.1",

src/dicta_sonicMic_3_device.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ export class SonicMic3Device extends DictationDeviceBase {
3636
const raw = data.getUint32(4, false);
3737
// TAB_FORWARD returns value "3", which is "11" in binary.
3838
// This makes it incompatible for single-bit bitmasking
39-
// So we return 2 (11) instead & map this in BUTTON_MAPPINGS
39+
// So we return 2 (10) instead & map this in BUTTON_MAPPINGS
4040
if (raw === 3) return 2;
4141
return raw;
4242
}

src/dictation_device_manager.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@ const DEVICE_FILTERS: Readonly<
7272
{vendorId: 0x0554, productId: 0x1001, usagePage: 1, usage: 0}),
7373
]),
7474
[ImplementationType.SONICMIC_3]: Object.freeze([
75-
// PowerMic III
75+
// SonicMic III
7676
Object.freeze(
7777
{vendorId: 0x15D8, productId: 0x002A, usagePage: 65280, usage: 1}),
7878
]),

0 commit comments

Comments
 (0)