diff --git a/frontend/src/scripts/test/layout-emulator.js b/frontend/src/scripts/test/layout-emulator.js index 7a0f9ce7f..35950c672 100644 --- a/frontend/src/scripts/test/layout-emulator.js +++ b/frontend/src/scripts/test/layout-emulator.js @@ -1,10 +1,10 @@ import Config from "../config"; import * as Misc from "../misc"; -import { capsLock } from "./caps-warning"; +import { capsState } from "./caps-warning"; export async function getCharFromEvent(event) { function emulatedLayoutShouldShiftKey(event, newKeyPreview) { - if (capsLock) return Misc.isASCIILetter(newKeyPreview) !== event.shiftKey; + if (capsState) return Misc.isASCIILetter(newKeyPreview) !== event.shiftKey; return event.shiftKey; } diff --git a/frontend/src/scripts/test/shift-tracker.js b/frontend/src/scripts/test/shift-tracker.js index 8c7814163..8025aa3b9 100644 --- a/frontend/src/scripts/test/shift-tracker.js +++ b/frontend/src/scripts/test/shift-tracker.js @@ -1,6 +1,6 @@ import Config from "../config"; import * as Misc from "../misc"; -import { capsLock } from "./caps-warning"; +import { capsState } from "./caps-warning"; export let leftState = false; export let rightState = false; @@ -19,7 +19,7 @@ function dynamicKeymapLegendStyle(uppercase) { const keys = keymapKeys.map((el) => el.childNodes[1]); - if (capsLock) uppercase = !uppercase; + if (capsState) uppercase = !uppercase; if (layoutKeys.filter((v) => v === undefined).length > 2) return;