mirror of
https://github.com/facebook/react-native.git
synced 2025-11-01 09:14:26 +00:00
Moved some NativeModule JS specs to OSS
Summary: For some reason the specs were internal, but the native impl is still in github. So let's move these to github for consistency. Changelog: [Internal] Reviewed By: hramos Differential Revision: D21419934 fbshipit-source-id: f2c4486edca43c4348f3a3c6ce98f76a322bab0b
This commit is contained in:
committed by
Facebook GitHub Bot
parent
41f0d9ba8f
commit
de667fffa4
@@ -0,0 +1,31 @@
|
||||
/**
|
||||
* (c) Facebook, Inc. and its affiliates. Confidential and proprietary.
|
||||
*
|
||||
* @flow strict-local
|
||||
* @format
|
||||
*/
|
||||
|
||||
'use strict';
|
||||
|
||||
import type {TurboModule} from '../TurboModule/RCTExport';
|
||||
import * as TurboModuleRegistry from '../TurboModule/TurboModuleRegistry';
|
||||
|
||||
export type TimePickerOptions = {|
|
||||
hour?: number,
|
||||
minute?: number,
|
||||
is24Hour?: boolean,
|
||||
mode?: string,
|
||||
|};
|
||||
|
||||
export type TimePickerResult = {|
|
||||
action: string,
|
||||
hour: number,
|
||||
minute: number,
|
||||
|};
|
||||
|
||||
export interface Spec extends TurboModule {
|
||||
// eslint-disable-next-line lint/react-native-modules
|
||||
+open: (options: TimePickerOptions) => Promise<TimePickerResult>;
|
||||
}
|
||||
|
||||
export default (TurboModuleRegistry.get<Spec>('TimePickerAndroid'): ?Spec);
|
||||
Reference in New Issue
Block a user