RCTMultilineTextInputNativeComponent.js 1.0 KB

1234567891011121314151617181920212223242526272829303132
  1. /**
  2. * Copyright (c) Facebook, Inc. and its 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. * @flow strict-local
  8. * @format
  9. */
  10. 'use strict';
  11. import type {HostComponent} from '../../Renderer/shims/ReactNativeTypes';
  12. import requireNativeComponent from '../../ReactNative/requireNativeComponent';
  13. import codegenNativeCommands from '../../Utilities/codegenNativeCommands';
  14. import type {Int32} from '../../Types/CodegenTypes';
  15. import type {TextInputNativeCommands} from './TextInputNativeCommands';
  16. import * as React from 'react';
  17. type NativeType = HostComponent<mixed>;
  18. type NativeCommands = TextInputNativeCommands<NativeType>;
  19. export const Commands: NativeCommands = codegenNativeCommands<NativeCommands>({
  20. supportedCommands: ['focus', 'blur', 'setTextAndSelection'],
  21. });
  22. const SinglelineTextInputNativeComponent: HostComponent<mixed> = requireNativeComponent<mixed>(
  23. 'RCTMultilineTextInputView',
  24. );
  25. export default SinglelineTextInputNativeComponent;