123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263 |
- /// <reference path="./types/index.d.ts" />
- interface VoiceProps {
- noMute?: boolean,
- pullUrls?: string[],
- pushUrl?: boolean
- sdkAppID?: number
- sig?: string
- action?: string
- userId?: string
- roomId?: string
- role?: string
- }
- interface GlobalUserInfo extends WechatMiniprogram.UserInfo {
- phoneNumber?: string
- wxUserId?: string
- }
- interface LoginProps {
- isLogin: boolean
- }
- interface GlobalDataProps {
- userInfo?: GlobalUserInfo,
- voiceProps?: VoiceProps,
- token: string,
- isLogin: boolean
- roomId: string
- }
- interface IAppOption {
- sleep: (ms: number) => Promise<any>
- globalData: GlobalDataProps
- userInfoReadyCallback?: WechatMiniprogram.GetUserInfoSuccessCallback,
- addVoicePropsListener?: (cb: Function) => void
- removeVoicePropsListener?: (cb: Function) => void
- setVoiceProps: (param: VoiceProps) => void
- setLogin: (status: boolean) => Promise<boolean>
- login: (slient?: boolean) => Promise<GlobalUserInfo | undefined>
- watch: (key: string, method: Function) => void
- unwatch: (key: string, method: Function) => void
- resetUserInfo: () => void
- }
- interface SocketParams {
- vruserId: string
- roomId: string
- role: string
- avatar: string
- name: string
- isTour: number
- m: string
- fromMiniApp: number
- vlog?: number
- wxToken?: string
- }
- interface SocketAction {
- type: string
- muted?: boolean
- userId?: string
- members?: any[]
- data: any
- }
|