diff --git a/types/expo/expo-tests.tsx b/types/expo/expo-tests.tsx index 5bb6b5abc4..75dee784de 100644 --- a/types/expo/expo-tests.tsx +++ b/types/expo/expo-tests.tsx @@ -145,7 +145,8 @@ Audio.setAudioModeAsync({ playsInSilentModeIOS: true, interruptionModeIOS: 2, interruptionModeAndroid: 1, - allowsRecordingIOS: true + allowsRecordingIOS: true, + playThroughEarpieceAndroid: false }); Audio.setIsEnabledAsync(true); diff --git a/types/expo/index.d.ts b/types/expo/index.d.ts index b406b4e8ec..ad94eb38ed 100644 --- a/types/expo/index.d.ts +++ b/types/expo/index.d.ts @@ -12,6 +12,7 @@ // Nathan Phillip Brink // Martin Olsson // Levan Basharuli +// Pavel Ihm // Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped // TypeScript Version: 2.8 @@ -405,6 +406,9 @@ export namespace Audio { /** an enum selecting how your experience’s audio should interact with the audio from other apps on Android: */ interruptionModeAndroid: InterruptionModeAndroid; + + /** Boolean selecting if audio should go to earpiece (only on Android).*/ + playThroughEarpieceAndroid: boolean; } function setIsEnabledAsync(value: boolean): Promise; @@ -566,7 +570,7 @@ export interface PlaybackStatusToSet { volume?: number; } -export type PlaybackSource = RequireSource | { uri: string } | Asset; +export type PlaybackSource = RequireSource | { uri: string, headers?: { [string]: string }, overrideFileExtensionAndroid?: string } | Asset; export class PlaybackObject { /** @@ -2355,7 +2359,7 @@ export namespace Calendar { /** Name for the account that owns this calendar */ ownerAccount?: string; // Android - /** Time zone for the calendar */ + /** Time zone for the calendar */ timeZone?: string; // Android /** Alarm methods that this calendar supports */ @@ -2398,7 +2402,7 @@ export namespace Calendar { /** Visible name of the event */ title?: string; - /** Location field of the event */ + /** Location field of the event */ location?: string; /** Date when the event record was created */