mirror of
https://github.com/danielsogl/awesome-cordova-plugins.git
synced 2025-01-19 08:32:52 +08:00
feat(mobile-messaging): add new fields to Message type and new method to display chat view (#3531)
Co-authored-by: Konstantin Latypov <Konstantin.Latypov@infobip.com>
This commit is contained in:
parent
7b0195bdf4
commit
14ec32b83c
@ -129,6 +129,11 @@ export interface Message {
|
||||
vibrate?: boolean; // Android only
|
||||
icon?: string; // Android only
|
||||
category?: string; // Android only
|
||||
chat?: string;
|
||||
browserUrl?: string;
|
||||
deeplink?: string;
|
||||
webViewUrl?: string;
|
||||
inAppDismissTitle?: string;
|
||||
}
|
||||
|
||||
export interface MobileMessagingError {
|
||||
@ -136,6 +141,12 @@ export interface MobileMessagingError {
|
||||
message: string;
|
||||
}
|
||||
|
||||
export interface ChatConfig {
|
||||
ios?: {
|
||||
showModally: boolean;
|
||||
};
|
||||
}
|
||||
|
||||
export class DefaultMessageStorage {
|
||||
@Cordova({ sync: true })
|
||||
find(messageId: string, callback: (message: Message) => void) {
|
||||
@ -437,4 +448,15 @@ export class MobileMessaging extends IonicNativePlugin {
|
||||
defaultMessageStorage(): DefaultMessageStorage | undefined {
|
||||
return;
|
||||
}
|
||||
|
||||
/**
|
||||
* Displays chat view.
|
||||
*
|
||||
* @name showChat
|
||||
* @param {ChatConfig} chat config
|
||||
*/
|
||||
@Cordova()
|
||||
showChat(config?: ChatConfig): Promise<any> {
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user