@phonghq/go-chat 1.0.16 → 1.0.18
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/chat/App.vue.d.ts +1 -1
- package/dist/components/chat/call/Calling.vue.d.ts +2 -33
- package/dist/go-chat.es.js +2133 -2127
- package/dist/go-chat.umd.js +6 -6
- package/dist/test/chat/App.vue.js +12 -5
- package/dist/test/components/chat/call/Calling.vue.js +2 -2
- package/dist/types/chat/global.d.ts +11 -5
- package/package.json +1 -1
|
@@ -144,15 +144,22 @@ const getResponsiveObserver = useDebounce(() => {
|
|
|
144
144
|
}
|
|
145
145
|
}
|
|
146
146
|
}, 50);
|
|
147
|
+
const getUserRemote = () => {
|
|
148
|
+
return callingRef.value?.userRemoter ?? null;
|
|
149
|
+
};
|
|
150
|
+
const startCall = () => {
|
|
151
|
+
return callingRef.value?.answer ?? undefined;
|
|
152
|
+
};
|
|
153
|
+
const endCall = () => {
|
|
154
|
+
return callingRef.value?.endCall;
|
|
155
|
+
};
|
|
147
156
|
initPage({ props: props, response: props.response });
|
|
148
157
|
let __VLS_exposed;
|
|
149
158
|
defineExpose({
|
|
150
159
|
unreadCount,
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
startCall: callingRef.value?.answer,
|
|
155
|
-
endCall: callingRef.value?.endCall,
|
|
160
|
+
getUserRemote,
|
|
161
|
+
startCall,
|
|
162
|
+
endCall,
|
|
156
163
|
});
|
|
157
164
|
debugger; /* PartiallyEnd: #3632/scriptSetup.vue */
|
|
158
165
|
const __VLS_defaults = {
|
|
@@ -209,8 +209,8 @@ const handleAfterClose = () => {
|
|
|
209
209
|
record_link.value = '';
|
|
210
210
|
uuidEnd = '';
|
|
211
211
|
};
|
|
212
|
-
|
|
213
|
-
defineExpose(
|
|
212
|
+
let __VLS_exposed;
|
|
213
|
+
defineExpose({ startCall, endCall, userRemoter, callStatus, answer, label });
|
|
214
214
|
debugger; /* PartiallyEnd: #3632/scriptSetup.vue */
|
|
215
215
|
const __VLS_defaults = {};
|
|
216
216
|
const __VLS_ctx = {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { ComputedRef } from 'vue';
|
|
1
|
+
import type { ComputedRef, Ref } from 'vue';
|
|
2
2
|
import type { IResUser } from '../../types/message';
|
|
3
3
|
import type { PLIVO_CALL_STATUS } from '../../types/call';
|
|
4
4
|
export type GoChatProps = {
|
|
@@ -10,10 +10,16 @@ export type GoChatProps = {
|
|
|
10
10
|
};
|
|
11
11
|
export interface GoChatInstance {
|
|
12
12
|
unreadCount: ComputedRef<number>;
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
startCall: (() => Promise<void>) | undefined;
|
|
13
|
+
getUserRemote: () => (IResUser | null);
|
|
14
|
+
startCall: any;
|
|
16
15
|
endCall: (() => void) | undefined;
|
|
17
|
-
|
|
16
|
+
}
|
|
17
|
+
export interface CallInstance {
|
|
18
|
+
userRemoter: Ref<IResUser | null>;
|
|
19
|
+
callStatus: Ref<PLIVO_CALL_STATUS | null>;
|
|
20
|
+
startCall: ((data: IResUser) => Promise<void>);
|
|
21
|
+
endCall: (() => void);
|
|
22
|
+
answer: (() => Promise<void>);
|
|
23
|
+
label: ComputedRef<any>;
|
|
18
24
|
}
|
|
19
25
|
export type PAGE_RESPONSE = 'mobile' | 'tablet';
|