Skip to content

Commit

Permalink
localization and tidyup
Browse files Browse the repository at this point in the history
  • Loading branch information
esheyw committed Feb 20, 2024
1 parent 74ba7f8 commit 1a27872
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 9 deletions.
9 changes: 6 additions & 3 deletions lang/en.json
Original file line number Diff line number Diff line change
@@ -1,10 +1,13 @@
{
{
"SettingsHotkeys": {
"Setting": {
"FocusBeforeClose": {
"Name": "Focus Before Close",
"Hint": "Should the hotkeys bring open windows to fore if open but not the current window, or always close a window if it's open?"
}
}
}
},
"ToggleSettings": "Toggle Configure Settings",
"ToggleControls": "Toggle Configure Controls",
"ToggleModules": "Toggle Module Management"
}
}
2 changes: 1 addition & 1 deletion scripts/constants.mjs
Original file line number Diff line number Diff line change
@@ -1 +1 @@
export const MODULE_ID = `settings-hotkeys`
export const MODULE_ID = "settings-hotkeys";
4 changes: 2 additions & 2 deletions scripts/init.mjs
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { registerKeybinds } from "./keybinds.mjs";
import { registerSettings } from "./settings.mjs";

Hooks.once('init', ()=> {
Hooks.once("init", () => {
registerSettings();
registerKeybinds();
});
});
6 changes: 3 additions & 3 deletions scripts/keybinds.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ function handleWindow(id) {

export function registerKeybinds() {
game.keybindings.register(MODULE, "settingsHotkey", {
name: `Toggle Settings Window`,
name: "SettingsHotkeys.ToggleSettings",
editable: [
{
key: "KeyZ",
Expand All @@ -37,7 +37,7 @@ export function registerKeybinds() {
onDown: () => handleWindow("client-settings"),
});
game.keybindings.register(MODULE, "keybindingsHotkey", {
name: `Open Configure Controls menu`,
name: "SettingsHotkeys.ToggleControls",
editable: [
{
key: "KeyX",
Expand All @@ -47,7 +47,7 @@ export function registerKeybinds() {
onDown: () => handleWindow("keybindings"),
});
game.keybindings.register(MODULE, "moduleManagementHotkey", {
name: `Open Module Management`,
name: "SettingsHotkeys.ToggleModules",
editable: [
{
key: "KeyZ",
Expand Down

0 comments on commit 1a27872

Please sign in to comment.