1 /* 2 * Copyright (c) Meta Platforms, Inc. and affiliates. 3 * 4 * This source code is licensed under the MIT license found in the 5 * LICENSE file in the root directory of this source tree. 6 */ 7 8 #import <UIKit/UIKit.h> 9 10 @interface ABI48_0_0RCTKeyCommands : NSObject 11 12 + (instancetype)sharedInstance; 13 14 /** 15 * Register a keyboard command. 16 */ 17 - (void)registerKeyCommandWithInput:(NSString *)input 18 modifierFlags:(UIKeyModifierFlags)flags 19 action:(void (^)(UIKeyCommand *command))block; 20 21 /** 22 * Unregister a keyboard command. 23 */ 24 - (void)unregisterKeyCommandWithInput:(NSString *)input modifierFlags:(UIKeyModifierFlags)flags; 25 26 /** 27 * Check if a command is registered. 28 */ 29 - (BOOL)isKeyCommandRegisteredForInput:(NSString *)input modifierFlags:(UIKeyModifierFlags)flags; 30 31 @end 32