CloseOnMove
Close / Exit in-game GUI's using movement keys, so you can make a quick getaway!
What does it do?
Are you like me? — Accidentally opening your inventory mid-battle, or panicking and forgetting how to close a chest when you hear the hissing of a Creeper? Then this mod is great for you!
Use W, A, S, D or Space to quickly close in-game GUI's such as the inventory, creative menu, chests, advancements screen etc. It's made so that if a text field is focused, the GUI is not closed so you can still type stuff in the recipe book or creative menu for example.
Do you use other keys to move, or just want to add more keys to exit GUI's? Use the closeonmove.json file in your config folder, or use Mod Menu in the mod versions of Minecraft 1.20.3 and above.

Dependencies
- Fabric API
- Mod Menu (Optional, for mod versions of Minecraft 1.20.3+)
Compatibility
I have not found any incompatibilities in terms of other mods, although Java 21 is required.
How to Install CloseOnMove (Mod)
CloseOnMove by heldheld is verified for Fabric across Minecraft versions 1.17, 1.17.1, 1.18, 1.18.1, 1.18.2, 1.19, 1.19.1, 1.19.2 (latest release: 1.0.2+1.21.9-1.21.11, file size: 26 KB). Follow the steps below to install it safely from ModCraft.tv:
- Click the Download button above and select your Minecraft version (1.17, 1.17.1, 1.18, 1.18.1, 1.18.2, 1.19, 1.19.1, 1.19.2) and platform (Fabric).
- Make sure you have the compatible loader or environment installed for Fabric.
- Move the downloaded CloseOnMove file into your Minecraft
.minecraft/modsfolder and launch the game.
All Versions
+ Add Version- Updated Mod Menu integration for 1.21.9+
- Updated Mod Menu integration for 1.21.6+
- Initial release for 1.20.3-1.21.5
- Initial release for 1.17-1.20.2