Added .js version of InputHandlerPattern