KeyboardEvent
Event payload for keyboard key-down notifications.
Delivered to Page.on_keyboard_event.
Inherits: Event
Properties
alt- Whether Alt was pressed when the key event was emitted.ctrl- Whether Control was pressed when the key event was emitted.key- The pressed key, such asA,ENTERorF5.meta- Whether Meta (Command/Windows) was pressed when the key event was emitted.shift- Whether Shift was pressed when the key event was emitted.
Properties
keyinstance-attribute
key: KeyboardKey | strThe pressed key, such as A,
ENTER or F5.
A key that has no KeyboardKey member is a plain string,
such as "Ü".
metainstance-attribute
meta: boolWhether Meta (Command/Windows) was pressed when the key event was emitted.