def METHOD_NAME(self, event: events.Key) -> None:
    """Called when the user presses a key."""
    def press(button_id: str) -> None:
        """Press a button, should it exist."""
        try:
            self.query_one(f"#{button_id}", Button).press()
        except NoMatches:
            pass
    key = event.key
    if key.isdecimal():
        press(f"number-{key}")
    elif key == "c":
        press("c")
        press("ac")
    else:
        button_id = self.NAME_MAP.get(key)
        if button_id is not None:
            press(self.NAME_MAP.get(key, key))