OptionalextendsPredefined mode to use as the base configuration. Defaults to default.
Optionalforwardhorizontal keeps forward/back movement level with the world; camera follows the camera direction.
OptionalkeyMode-specific shortcut overrides. Empty arrays disable the default bindings for that action.
OptionalkeyboardEnable keyboard movement actions. Automatically enabled when navigation key bindings are supplied.
OptionallookEnable drag look-around when a binding maps to lookAround.
OptionalnavigationMode-level multiplier for free keyboard navigation speed. The predefined drone mode defaults to 3.
OptionalpointerRequest pointer lock when the mode starts and use mouse movement for look-around.
OptionalturnUse left/right keyboard bindings to yaw instead of strafe. Used by the predefined walk mode.
OptionaltypeAlias for extends, kept for callers that prefer describing the movement type.
Defines one custom navigation mode. The four predefined modes are available as presets through
extends:default: regular orbit/pan/zoom mouse navigation, no keyboard movement.walk: keyboard forward/back/up/down movement, left/right keyboard turning and Alt+left-button look-around.game: pointer-lock look-around with horizontal WASD/arrow movement.drone: pointer-lock look-around with camera-direction WASD/arrow movement.Custom modes can map one or more keyboard or mouse combinations to any action supported by
NavigationModeSettingswithkeyBindings. AKeyBindinguses DOMKeyboardEvent.codevalues such asKeyW,ArrowUporPageDown, and DOM mouse button numbers:0main/left button,1middle button and2secondary/right button. Navigation movement bindings can setspeedto scale that binding's movement or turn speed. For example,{ keyCode: "ArrowUp", speed: 1 }and{ keyCode: "ArrowUp", shiftKey: true, speed: 5 }keep the current fast-shift behavior configurable per binding.Example