diff --git a/.gitignore b/.gitignore index 52557d26a..057927011 100644 --- a/.gitignore +++ b/.gitignore @@ -73,3 +73,4 @@ xcuserdata* samples/**/package-lock.json *.iml android/bin +lib diff --git a/.npmignore b/.npmignore index b70036704..819a468c5 100644 --- a/.npmignore +++ b/.npmignore @@ -3,7 +3,6 @@ *.md *.MD .DS_Store -tsconfig.json samples __tests__ docs diff --git a/lib/AgoraView.native.js b/lib/AgoraView.native.js deleted file mode 100644 index 2228ccbe7..000000000 --- a/lib/AgoraView.native.js +++ /dev/null @@ -1,42 +0,0 @@ -"use strict"; -Object.defineProperty(exports, "__esModule", { value: true }); -const tslib_1 = require("tslib"); -const react_1 = tslib_1.__importDefault(require("react")); -const react_native_1 = require("react-native"); -/** - * Import RCTAgoraView from native binding. - * - * This @object is used to bridge native layer between react layer. - */ -const RCTAgoraView = react_native_1.requireNativeComponent("RCTAgoraView"); -/** - * AgoraView is the render layer for rendering video stream - * - * This class is used to rendering native sdk stream - * - * @props {@link AgoraViewProps} - */ -class AgoraView extends react_1.default.Component { - /** - * render - * - * It would render view for VideoStream - */ - render() { - return (react_1.default.createElement(RCTAgoraView, Object.assign({}, this.getHTMLProps()))); - } - /** - * getHTMLProps - * - * get agora view props - */ - getHTMLProps() { - let htmlProps = {}; - for (let key in this.props) { - htmlProps[key] = this.props[key]; - } - return htmlProps; - } -} -exports.default = AgoraView; -//# sourceMappingURL=AgoraView.native.js.map \ No newline at end of file diff --git a/lib/AgoraView.native.js.map b/lib/AgoraView.native.js.map deleted file mode 100644 index 1f1e31824..000000000 --- a/lib/AgoraView.native.js.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"file":"AgoraView.native.js","sourceRoot":"","sources":["../src/AgoraView.native.tsx"],"names":[],"mappings":";;;AAAA,0DAA0B;AAC1B,+CAEqB;AAMrB;;;;GAIG;AAEH,MAAM,YAAY,GAAG,qCAAsB,CAAC,cAAc,CAAC,CAAC;AAE5D;;;;;;GAMG;AACH,MAAqB,SAAU,SAAQ,eAAK,CAAC,SAAyB;IAClE;;;;OAIG;IACI,MAAM;QACT,OAAO,CACH,8BAAC,YAAY,oBAAM,IAAI,CAAC,YAAY,EAAE,EAAK,CAC9C,CAAA;IACL,CAAC;IAED;;;;OAIG;IACK,YAAY;QAChB,IAAI,SAAS,GAAG,EAAoB,CAAC;QACrC,KAAK,IAAI,GAAG,IAAI,IAAI,CAAC,KAAK,EAAE;YACxB,SAAS,CAAC,GAAG,CAAC,GAAG,IAAI,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC;SACpC;QACD,OAAO,SAAS,CAAC;IACrB,CAAC;CACJ;AAxBD,4BAwBC"} \ No newline at end of file diff --git a/lib/RtcEngine.native.js b/lib/RtcEngine.native.js deleted file mode 100644 index 25922b3f4..000000000 --- a/lib/RtcEngine.native.js +++ /dev/null @@ -1,1216 +0,0 @@ -"use strict"; -Object.defineProperty(exports, "__esModule", { value: true }); -const react_native_1 = require("react-native"); -const { Agora } = react_native_1.NativeModules; -const AgoraEventEmitter = new react_native_1.NativeEventEmitter(Agora); -/** - * RtcEngine is the javascript object for control agora native sdk through react native bridge. - * - * You can use the RtcEngine methods to create {@link init} - * - * Other methods of the RtcEngine object serve for agora native sdk and set up error logging. - */ -class RtcEngine { - /** - * Creates a RtcEngine Object internal. - * - * This method creates and start event observer. You should call this method once. - * @example `RtcEngine.init(option)` - * @param options Defines the property of the client, see {@link Option} for details. - */ - static init(options) { - Agora.init(options); - } - /** - * join specified channel - * - * This method joins and begin rendering the video stream. when join succeeds. - * Otherwise, it will invoke error by the event - * @param channelName - * @param uid - * @param token - * @param info - */ - static joinChannel(channelName, uid, token, info) { - return Agora.joinChannel({ channelName, uid, token, info }); - } - /** - * add event listener - * - * This method subscribes specified eventType and run listener. You should call this method at first. - * @param eventType - * @param listener - */ - static on(eventType, listener) { - this.eventTypes.add(eventType); - AgoraEventEmitter.addListener(eventType, listener); - } - /** - * remove event listeners - * - * This method unsubscribes specified eventType related all listeners. You should call this method when you want to unsubscribe some eventType. - * @param eventType - */ - static off(eventType) { - AgoraEventEmitter.removeAllListeners(eventType); - this.eventTypes.delete(eventType); - } - /** - * remove all events listeners - * - * This method unsubscribes all eventTypes related listeners. - * - * @param token - */ - static removeAllListeners() { - for (let eventType of this.eventTypes) { - AgoraEventEmitter.removeAllListeners(eventType); - } - this.eventTypes.clear(); - } - /** - * renew token - * - * This method renews a new token. - * @param token - */ - static renewToken(token) { - return Agora.renewToken(token); - } - /** - * enable websdk interoperability - * - * This method used to enable websdk interoperability, so that it can connect with agora websdk apps. - * - * @param enabled - * @returns Promise<{success, value}> - */ - static enableWebSdkInteroperability(enabled) { - return Agora.enableWebSdkInteroperability(enabled); - } - /** - * get agora native sdk connection state - * - * This method gets agora native sdk connection state - * @returns Promise<{success: true, state: (connection state)}> - */ - static getConnectionState() { - return Agora.getConnectionState(); - } - /** - * change the client role - * - * This method changes the client of role. - * @param role (audience: 0, host: 1) - */ - static setClientRole(role) { - Agora.setClientRole(role); - } - /** - * leave channel - * - * This method leaves the joined channel, then your video view will not render ever. - * You should call it, when you dont need render video stream. - * - * @returns Promise<{success, value}> - */ - static leaveChannel() { - return Agora.leaveChannel(); - } - /** - * destroy - * - * This method stops event subscribe and destroy the RtcEngine instance's. - * You should call it, when you want to destroy the engine. - * - * @returns Promise<{success, value}> - */ - static destroy() { - return Agora.destroy(); - } - /** - * show local video - * - * This method calls native sdk render canvas for local video. - * @param options {@link VideoOption} - */ - static setupLocalVideo(options) { - Agora.setupLocalVideo(options); - } - /** - * show remote video - * - * This method calls native sdk render canvas for remote video. - * @param options {@link VideoOption} - */ - static setupRemoteVideo(options) { - Agora.setupRemoteVideo(options); - } - /** - * set local video render mode - * - * This method calls native sdk render mode for local video. - * @param mode - */ - static setLocalRenderMode(mode) { - Agora.setLocalRenderMode(mode); - } - /** - * set the specified remote video render mode - * - * This method calls native sdk render mode for the specified remote video. - * - * @param uid - * @param mode - */ - static setRemoteRenderMode(uid, mode) { - Agora.setRemoteRenderMode(uid, mode); - } - /** - * start video preview - * - * This method start video preview for video. - */ - static startPreview() { - Agora.startPreview(); - } - /** - * stop video preview - * - * This method stops video preview for video. - */ - static stopPreview() { - Agora.stopPreview(); - } - /** - * set enable speaker phone - * - * This method set the speaker phone enable or disable by pass boolean parameter. - * @param enabled - */ - static setEnableSpeakerphone(enabled) { - Agora.setEnableSpeakerphone(enabled); - } - /** - * set default audio speaker - * - * This method set the default audio speaker enable or disable by pass boolean parameter. - * @param enabled - */ - static setDefaultAudioRouteToSpeakerphone(enabled) { - Agora.setDefaultAudioRouteToSpeakerphone(enabled); - } - /** - * set default mute all remote audio streams - * - * This method set default mute all remote audio streams enable or not by pass boolean parameter. - * @param enabled - */ - static setDefaultMuteAllRemoteAudioStreams(enabled) { - Agora.setDefaultMuteAllRemoteAudioStreams(enabled); - } - /** - * enable video - * - * This method enables video. - */ - static enableVideo() { - Agora.enableVideo(); - } - /** - * disable video - * - * This method disables video. - */ - static disableVideo() { - Agora.disableVideo(); - } - /** - * enable local video - * - * This method enables the local video by the boolean parameter. - * @param enabled - */ - static enableLocalVideo(enabled) { - Agora.enableLocalVideo(enabled); - } - /** - * mute local video stream - * - * This method mutes video stream by the boolean parameter. - * @param muted - */ - static muteLocalVideoStream(muted) { - Agora.muteLocalVideoStream(muted); - } - /** - * mute all remote video streams - * - * This method mutes all remote streams by the boolean parameter. - * @param muted - */ - static muteAllRemoteVideoStreams(muted) { - Agora.muteAllRemoteVideoStreams(muted); - } - /** - * mute specified remote video stream. - * - * This method mutes remote video stream by the number of uid and boolean parameter. - * @param uid - * @param muted - */ - static muteRemoteVideoStream(uid, muted) { - Agora.muteRemoteVideoStream(uid, muted); - } - /** - * set default mute all remote video stream - * - * This method mutes all remote video stream default by the boolean parameter. - * @param muted - */ - static setDefaultMuteAllRemoteVideoStreams(muted) { - Agora.setDefaultMuteAllRemoteVideoStreams(muted); - } - /** - * enable audio - * - * This method enables audio - */ - static enableAudio() { - Agora.enableAudio(); - } - /** - * disable audio - * - * This method disables audio - */ - static disableAudio() { - Agora.disableAudio(); - } - /** - * enable local audio - * - * This method enables local audio by the boolean parameter. - * @param enabled - */ - static enableLocalAudio(enabled) { - Agora.enableLocalAudio(enabled); - } - /** - * mute local audio stream - * - * This method mutes the local audio stream by muted. - * @param muted - */ - static disableLocalAudio(muted) { - Agora.disableLocalAudio(muted); - } - /** - * mute all remote audio streams - * - * This method mutes all remote audio streams by muted - */ - static muteAllRemoteAudioStreams(muted) { - Agora.muteAllRemoteAudioStreams(muted); - } - /** - * mute specified remote audio stream by muted - * - * This method mutes specified remote audio stream by number uid and boolean muted. - * @param uid - * @param muted - */ - static muteRemoteAudioStream(uid, muted) { - Agora.muteRemoteAudioStream(uid, muted); - } - /** - * adjust recording signal volume - * - * This method adjusts recording your signal by volume. - * @param volume - */ - static adjustRecordingSignalVolume(volume) { - Agora.adjustRecordingSignalVolume(volume); - } - /** - * adjust playback signal volume - * - * This method adjusts playback signal by volume. - * @param volume - */ - static adjustPlaybackSignalVolume(volume) { - Agora.adjustPlaybackSignalVolume(volume); - } - /** - * enable audio volume indication - * - * This method enables audio volume by interval and smooth - * @param interval - * @param smooth - */ - static enableAudioVolumeIndication(interval, smooth) { - Agora.enableAudioVolumeIndication(interval, smooth); - } - /** - * create data stream - * - * This method creates data stream with options - * - * @param options {@link DataStreamOption} - */ - static createDataStream(options) { - return Agora.createDataStream(options); - } - /** - * check for mobile phone speaker enabled - * - * This method checks the phone speaker is enabled - * @param callback - */ - static methodisSpeakerphoneEnabled(callback) { - Agora.methodisSpeakerphoneEnabled(callback); - } - /** - * enable in-ear monitor - * - * This method enables in-ear monitoring by boolean parameter enabled - * - * @param enabled - */ - static enableInEarMonitoring(enabled) { - Agora.enableInEarMonitoring(enabled); - } - /** - * set in-ear monitoring volume - * - * This method sets the in-ear-monitoring volume by number parameter volume - * - * @param volume - */ - static setInEarMonitoringVolume(volume) { - Agora.setInEarMonitoringVolume(volume); - } - /** - * set local voice pitch - * - * This method sets the local voice pitch by float parameter pitch - * - * @param pitch - */ - static setLocalVoicePitch(pitch) { - Agora.setLocalVoicePitch(pitch); - } - /** - * set local voice equalization - * - * This method set local video equalization of band frequency by enum band number and number of gain - * - * @param band - * @param gain - */ - static setLocalVoiceEqualization(band, gain) { - Agora.setLocalVoiceEqualization(band, gain); - } - /** - * set local voice reverb - * - * This method sets local voice by reverb and value - * @param reverb - * @param value - */ - static setLocalVoiceReverb(reverb, value) { - Agora.setLocalVoiceReverb(reverb, value); - } - /** - * start audio mixing - * - * This method will start audio mixing by option config - * - * @param options {@link AudioMixingOption} - */ - static startAudioMixing(options) { - Agora.startAudioMixing(options); - } - /** - * stop audio mixing - * - * This methods stops for audio mixing. - */ - static stopAudioMixing() { - Agora.stopAudioMixing(); - } - /** - * pause audio mixing - * - * This method pauses for audio mixing. - */ - static pauseAudioMixing() { - Agora.pauseAudioMixing(); - } - /** - * resume audio mixing - * - * This method resumes for audio mixing. - */ - static resumeAudioMixing() { - Agora.resumeAudioMixing(); - } - /** - * adjust audio mixing volume - * - * This method adjusts audio mixing volume by the volume number parameter - * @param volume - */ - static adjustAudioMixingVolume(volume) { - Agora.adjustAudioMixingVolume(volume); - } - /** - * adjust audio mixing playout volume - * - * This method adjusts audio mixing playout by the volume parameter - * @param volume - */ - static adjustAudioMixingPlayoutVolume(volume) { - Agora.adjustAudioMixingPlayoutVolume(volume); - } - /** - * adjust audio mixing publish volume - * - * This method adjusts audio mixing publish by the volume paraemter - * @param volume - */ - static adjustAudioMixingPublishVolume(volume) { - Agora.adjustAudioMixingPublishVolume(volume); - } - /** - * get audio mixing duration - * - * This method gets the audio mixing duration - * @returns Promise<{success, value}> - */ - static getAudioMixingDuration() { - return Agora.getAudioMixingDuration(); - } - /** - * get audio mixing current position - * - * This method gets audio mixing current position value. - * @returns Promise<{success, value}> - */ - static getAudioMixingCurrentPosition() { - return Agora.getAudioMixingCurrentPosition(); - } - /** - * set audio mixing position - * - * This method sets audio mixing position by the parameter pos - * @param pos - */ - static setAudioMixingPosition(pos) { - return Agora.setAudioMixingPosition(pos); - } - /** - * get effects of volume - * - * This methods get audio mixing effects volume value. - * @returns Promise<{success, value}> - */ - static getEffectsVolume() { - return Agora.getEffectsVolume(); - } - /** - * set effects volume - * - * This methods set audio mixing effects volume by float parameter. - * @param volume - * @returns Promise<{success, value}> - */ - static setEffectsVolume(volume) { - return Agora.setEffectsVolume(volume); - } - /** - * set volume for playing effects. - * - * This methods set for playing audio mixing effects - * @returns Promise<{success, value}> - */ - static setVolumeOfEffect(volume) { - return Agora.setVolumeOfEffect(volume); - } - /** - * play specified effect for audio mixing - * - * This methos plays the specified effect of audio mixing file by option config. - * @param options {@link PlayEffectOption} - * @returns Promise<{success, value}> - */ - static playEffect(options) { - return Agora.playEffect(options); - } - /** - * stop play effect for audio mixing - * - * This methods stops the specified effect for audio mixing file by soundid. - * @param sounid - * @returns Promise<{success, value}> - */ - static stopEffect(soundId) { - return Agora.stopEffect(soundId); - } - /** - * stop play all for effect audio mixing. - * - * This methods stops all effect audio mixing. - * @returns Promise<{success, value}> - */ - static stopAllEffects() { - return Agora.stopAllEffects(); - } - /** - * preload effect for audio mixing file. - * - * This methods preloads the specified audio mixing file to memory by the soundid - * @param soundid - * @param filepath - * @returns Promise<{success, value}> - */ - static preloadEffect(soundId, filepath) { - return Agora.preloadEffect(soundId, filepath); - } - /** - * unload effect - * - * This methods unload the already loaded audio mixing file from memory by the soundid. - * @param soundid - * @returns Promise<{success, value}> - */ - static unloadEffect(soundId) { - return Agora.unloadEffect(soundId); - } - /** - * pause the specified effect for audio mixing by soundid - * - * This method pauses the specified effect for audio mixing by soundid. - * @param soundid - * @returns Promise<{success, value}> - */ - static pauseEffect(soundId) { - return Agora.pauseEffect(soundId); - } - /** - * pause all effects for audio mixing - * - * This method pause all effects for audio mixing. - * @param soundid - * @returns Promise<{success, value}> - */ - static pauseAllEffects() { - return Agora.pauseAllEffects(); - } - /** - * resume audio mixing effect by the specified soundid - * - * This method resumes audio mixing effect by the specified soundid - * @param soundid - * @returns Promise<{success, value}> - */ - static resumeEffect(soundId) { - return Agora.resumeEffect(soundId); - } - /** - * resume all audio mixing effects. - * - * This method resumes all audio mixing effects. - * @returns Promise<{success, value}> - */ - static resumeAllEffects() { - return Agora.resumeAllEffects(); - } - /** - * start audio recording by quality - * - * This method start audio recording by quality config - * @param options {@link AudioRecordingOption} - * @returns Promise<{success, value}> - */ - static startAudioRecording(options) { - return Agora.startAudioRecording(options); - } - /** - * stop audio recording - * - * This method stops audio recording. - * @returns Promise<{success, value}> - */ - static stopAudioRecording() { - return Agora.stopAudioRecording(); - } - /** - * set audio session operation restriction - * - * The SDK and the app can both configure the audio session by default. The app may occasionally use other apps or third-party components to manipulate the audio session and restrict the SDK from doing so. This method allows the app to restrict the SDK’s manipulation of the audio session. - * You can call this method at any time to return the control of the audio sessions to the SDK. - * This method restricts the SDK’s manipulation of the audio session. Any operation to the audio session relies solely on the app, other apps, or third-party components. - * @notice iOS support only - */ - static setAudioSessionOperationRestriction() { - if (react_native_1.Platform.OS != 'ios') - throw Error(`setAudioSessionOperationRestriction is not support on your platform. Please check the details in react-native-agora docs`); - Agora.setAudioSessionOperationRestriction(); - } - /** - * @deprecated - * start echo test - * - * This method launches an audio call test to determine whether the audio devices (for example, headset and speaker) and the network connection are working properly. - * @returns Promise<{success, value}> - */ - // public static startEchoTest(): Promise { - // return Agora.startEchoTest(); - // } - /** - * stop echo test - * - * This method stop launched an audio call test. - * @returns Promise<{success, value}> - */ - static stopEchoTest() { - return Agora.stopEchoTest(); - } - /** - * enable lastmile test - * - * This method enables the network connection qualit test. - * - * @returns Promise<{success, value}> - */ - static enableLastmileTest() { - return Agora.enableLastmileTest(); - } - /** - * disable lastmile test - * - * This method disable the network connection qualit test. - * - * @returns Promise<{success, value}> - */ - static disableLastmileTest() { - return Agora.disableLastmileTest(); - } - /** - * set recording audio frame parameters - * - * This method Sets the audio recording format for the audioFrame callback. - * - * @param options {@link RecordingAudioFrameOption} - * @returns Promise<{success, value}> - */ - static setRecordingAudioFrameParameters(options) { - return Agora.setRecordingAudioFrameParameters(options); - } - /** - * set playback audio frame parameters - * - * This method Sets the audio frame format for the playbackFrame callback. - * - * @param options {@link AudioFrameOption} - * @returns Promise<{success, value}> - */ - static setPlaybackAudioFrameParameters(options) { - return Agora.setPlaybackAudioFrameParameters(options); - } - /** - * set mixed audio frame parameters - * - * This method Sets the audio frame format for the mixedAudioFrame callback. - * - * @param options {@link MixedAudioFrameOption} - * @returns Promise<{success, value}> - */ - static setMixedAudioFrameParameters(options) { - return Agora.setMixedAudioFrameParameters(options); - } - /** - * add video watermark - * - * This method adds video watermark to the local video. - * - * @param options {@link ImageOption} - * @returns Promise<{success, value}> - */ - static addVideoWatermark(options) { - return Agora.addVideoWatermark(options); - } - /** - * clear video watermarks - * - * This method removes the watermark image from the video stream added by addVideoWatermark. - * - * @returns Promise<{success, value}> - */ - static removclearVideoWatermarkse() { - return Agora.clearVideoWatermarks(); - } - /** - * set local publish fallback - * - * This method sets the fallback option for the locally published video stream based on the network conditions. - * - * @param option {0, 1, 2} [more details](https://docs.agora.io/en/Video/API%20Reference/java/classio_1_1agora_1_1rtc_1_1_constants.html#a3e453c93766e783a7e5eca05b1776238) - * @returns Promise<{success, value}> - */ - static setLocalPublishFallbackOption(option) { - return Agora.setLocalPublishFallbackOption(option); - } - /** - * set remote publish fallback - * - * This method sets the fallback option for the remotely subscribed video stream based on the network conditions. - * - * @param option {0, 1, 2} [more details](https://docs.agora.io/en/Video/API%20Reference/java/classio_1_1agora_1_1rtc_1_1_constants.html#a3e453c93766e783a7e5eca05b1776238) - * @returns Promise<{success, value}> - */ - static setRemoteSubscribeFallbackOption(option) { - return Agora.setRemoteSubscribeFallbackOption(option); - } - /** - * enable dual stream mode - * - * This method enables the dual stream by parameter mode. - * - * @param enabled - * @returns Promise<{success, value}> - */ - static enableDualStreamMode(enabled) { - return Agora.enableDualStreamMode(enabled); - } - /** - * set remote video stream type - * - * This method sets the remote video stream type by uid and streamType. - * - * @param options {@link VideoStreamOption} - * @returns Promise<{success, value}> - */ - static setRemoteVideoStreamType(options) { - return Agora.setRemoteVideoStreamType(options); - } - /** - * set remote default video stream type - * - * This method sets the default video stream type. - * - * @param options {@link DefaultVideoStreamOption} - * @returns Promise<{success, value}> - */ - static setRemoteDefaultVideoStreamType(options) { - return Agora.setRemoteDefaultVideoStreamType(options); - } - /** - * add inject stream url - * - * This method injects an online media stream to a live broadcast. - * - * @param options {@link InjectStreamOption} - * @returns Promise<{success, value}> - */ - static addInjectStreamUrl(options) { - return Agora.addInjectStreamUrl(options); - } - /** - * remove inject stream url - * - * This method removes stream by addInjectsStreamUrl. - * - * @param options {@link RemoveInjectStreamOption} - * @returns Promise<{success, value}> - */ - static removeInjectStreamUrl(options) { - return Agora.removeInjectStreamUrl(options); - } - /** - * @deprecated - * set video quality - * - * This method sets the preferences for the video quality. (Live broadcast only). - * - * @param quality boolean - * @returns Promise<{success, value}> - */ - // public static setVideoQualityParameters(quality: boolean): Promise { - // return Agora.setVideoQualityParameters(quality); - // } - /** - * set local video mirror mode - * - * This method sets local video mirror mode - * - * @param mode - * @returns Promise<{success, value}> - */ - static setLocalVideoMirrorMode(mode) { - return Agora.setLocalVideoMirrorMode(mode); - } - /** - * switch camera - * - * This method switches camera between front and rear. - * - * @returns Promise<{success, value}> - */ - static switchCamera() { - return Agora.switchCamera(); - } - /** - * is camera zoom supported - * - * This method checks whether the camera zoom function is supported. - * - * @returns Promise<{success, value}> - */ - static isCameraZoomSupported() { - return Agora.isCameraZoomSupported(); - } - /** - * is camera torch supported - * - * This method checks whether the camera flash function is supported. - * - * @returns Promise<{success, value}> - */ - static isCameraTorchSupported() { - return Agora.isCameraTorchSupported(); - } - /** - * is camera focus supported - * - * This method checks whether the camera mannual focus function is supported. - * - * @returns Promise<{success, value}> - */ - static isCameraFocusSupported() { - return Agora.isCameraFocusSupported(); - } - /** - * is camera exposure position supported - * - * This method checks whether the camera mannual exposure function is supported. - * - * @returns Promise<{success, value}> - */ - static isCameraExposurePositionSupported() { - return Agora.isCameraExposurePositionSupported(); - } - /** - * is camera auto focus face mode supported - * - * This method checks whether the camera mannual auto-face focus function is supported. - * - * @returns Promise<{success, value}> - */ - static isCameraAutoFocusFaceModeSupported() { - return Agora.isCameraAutoFocusFaceModeSupported(); - } - /** - * set camera zoom ratio - * - * This method sets the camera zoom ratio. - * - * @param zoomFactor - * @returns Promise<{success, value}> - */ - static setCameraZoomFactor(zoomFactor) { - return Agora.setCameraZoomFactor(zoomFactor); - } - /** - * get camera max zoom ratio - * - * This method gets the camera maximum zoom ratio. - * - * @notice Android Only - * @returns Promise<{success, value}> - */ - static getCameraMaxZoomFactor() { - return Agora.getCameraMaxZoomFactor(); - } - /** - * set camera focus position in preview - * - * This method sets the mannual focus position. - * - * @param options {@link PositionOption} - * @returns Promise<{success, value}> - */ - static setCameraFocusPositionInPreview(options) { - return Agora.setCameraFocusPositionInPreview(options); - } - /** - * set camera exposure position - * - * This method sets the mannual exposure position. - * - * @param options {@link PositionOption} - * @returns Promise<{success, value}> - */ - static setCameraExposurePosition(options) { - return Agora.setCameraExposurePosition(options); - } - /** - * set camera torch on - * - * This method enables the camera flash function. - * - * @param enabled - * @returns Promise<{success, value}> - */ - static setCameraTorchOn(enabled) { - return Agora.setCameraTorchOn(enabled); - } - /** - * set enable auto focus face mode - * - * This method enables auto-focus face mode function. - * - * @param enabled boolean - * @returns Promise<{success, value}> - */ - static setCameraAutoFocusFaceModeEnabled(enabled) { - return Agora.setCameraAutoFocusFaceModeEnabled(enabled); - } - /** - * get call id - * - * This method is used to get call id. - * - * @returns Promise<{success, value}> - */ - static getCallId() { - return Agora.getCallId(); - } - /** - * set log file and log filter - * - * This method sets the log file generated path and specified the log level. - * - * @param filepath string - * @param level enum - * @param maxfileSize integer (KB) - * @returns Promise<{success, value}> - */ - static setLog(filepath, level, maxfileSize) { - return Agora.setLog(filepath, level, maxfileSize); - } - /** - * send stream message - * - * This method sends stream message by specified uid - * - * @param uid - * @param data - * @returns Promise<{success, value}> - */ - static sendMessage(streamID, data, reliable, ordered) { - return Agora.sendMessage({ streamID, data, reliable, ordered }); - } - /** - * add publish stream url - * - * This method add publish stream by option. - * - * @param options {@link PublishStreamOption} - * @returns Promise<{success, value}> - */ - static addPublishStreamUrl(options) { - return Agora.addPublishStreamUrl(options); - } - /** - * remove publish stream url - * - * This method remove publish stream by options. - * - * @param options {@link RemovePublishStreamOption} - * @returns Promise<{success, value}> - */ - static removePublishStreamUrl(options) { - return Agora.removePublishStreamUrl(options); - } - /** - * set live transcoding - * - * This method sets the video layout and audio settings for CDN live. - * - * @param options {@link LiveTranscoding} - * @returns Promise<{success, value}> - */ - static setLiveTranscoding(options) { - return Agora.setLiveTranscoding(options); - } - /** - * get sdk version - * - * This method gets the sdk version details and passed it into callback function - * - * @param callback to handle resolve from getSdkVersion - * @param errorHandler to handle reject error from getSdkVersion - */ - static getSdkVersion(callback, errorHandler) { - return Agora.getSdkVersion().then(callback).catch(errorHandler); - } - /** - * mute local audio stream - * - * This method sends/stops sending the local audio. - * - * @param enabled - */ - static muteLocalAudioStream(enabled) { - Agora.muteLocalAudioStream(enabled); - } - /** - * video pre-process/post-process - * - * This method enables/disables image enhancement and sets the options. - * - * @param enable boolean - * @param options {@link BeautyOptions} - * @returns Promise<{success, value}> - */ - static setBeautyEffectOptions(enabled, options) { - return Agora.setBeautyEffectOptions(enabled, options); - } - /** - * set local voice change - * - * This method changes local speaker voice with voiceChanger - * - * @param voiceChanger integer - * @voiceChanger value ranges [ - * 0: "The original voice", - * 1: "An old man’s voice", - * 2: "A little boy’s voice.", - * 3: "A little girl’s voice.", - * 4: "TBD", - * 5: "Ethereal vocal effects.", - * 6: "Hulk’s voice." - * ] - * @returns Promise<{success, value}> - */ - static setLocalVoiceChanger(voiceChanger) { - return Agora.setLocalVoiceChanger(voiceChanger); - } - /** - * set the preset local voice reverberation effect. - * - * This method sets the preset local voice reverberation effect. - * - * @param preset integer - * @returns Promise<{success, value}> - */ - static setLocalVoiceReverbPreset(preset) { - return Agora.setLocalVoiceReverbPreset(preset); - } - /** - * control stereo panning for remote users - * - * This method enables/disables stereo panning for remote users. - * - * @param enabled boolean - * @returns Promise<{success, value}> - */ - static enableSoundPositionIndication(enabled) { - return Agora.enableSoundPositionIndication(enabled); - } - /** - * set the sound position of a remote user - * - * This method sets the sound position of a remote user by uid - * - * @param uid number | The ID of the remote user - * @param pan float | The sound position of the remote user. The value ranges from -1.0 to 1.0 - * @pan - * 0.0: the remote sound comes from the front. - * -1.0: the remote sound comes from the left. - * 1.0: the remote sound comes from the right. - * @param gain float | Gain of the remote user. The value ranges from 0.0 to 100.0. The default value is 100.0 (the original gain of the remote user). The smaller the value, the less the gain. - * @returns Promise<{success, value}> - */ - static setRemoteVoicePosition(uid, pan, gain) { - return Agora.setRemoteVoicePosition(uid, pan, gain); - } - /** - * start the lastmile probe test - * - * This method start the last-mile network probe test before joining a channel to get the uplink and downlink last-mile network statistics, including the bandwidth, packet loss, jitter, and round-trip time (RTT). - * - * @param config LastmileProbeConfig {@link LastmileProbeConfig} - * - * @event onLastmileQuality: the SDK triggers this callback within two seconds depending on the network conditions. This callback rates the network conditions with a score and is more closely linked to the user experience. - * @event onLastmileProbeResult: the SDK triggers this callback within 30 seconds depending on the network conditions. This callback returns the real-time statistics of the network conditions and is more objective. - * @returns Promise<{success, value}> - */ - static startLastmileProbeTest(config) { - return Agora.startLastmileProbeTest(config); - } - /** - * stop the lastmile probe test - * - * This method stop the lastmile probe test. - * - * @returns Promise<{success, value}> - */ - static stopLastmileProbeTest() { - return Agora.stopLastmileProbeTest(); - } - /** - * sets the priority of a remote user's media stream. - * - * note: Use this method with the setRemoteSubscribeFallbackOption method. If the fallback function is enabled for a subscribed stream, the SDK ensures the high-priority user gets the best possible stream quality. - * - * This method sets the priority of a remote user's media stream. - * @param uid number - * @param userPriority number | The value range is [50 is "user's priority is hgih", 100 is "the default user's priority is normal"] - * - * @returns Promise<{success, value}> - */ - static setRemoteUserPriority(uid, userPrority) { - return Agora.setRemoteUserPriority(uid, userPrority); - } - /** - * start an audio call test. - * - * note: - * Call this method before joining a channel. - * After calling this method, call the stopEchoTest method to end the test. Otherwise, the app cannot run the next echo test, or call the joinchannel method. - * In the Live-broadcast profile, only a host can call this method. - * This method will start an audio call test with interval parameter. - * In the audio call test, you record your voice. If the recording plays back within the set time interval, the audio devices and the network connection are working properly. - * - * @param interval number - * - * @returns Promise<{success, value}> - */ - static startEchoTestWithInterval(interval) { - return Agora.startEchoTestWithInterval(interval); - } - /** - * set the camera capture preference. - * - * note: - * For a video call or live broadcast, generally the SDK controls the camera output parameters. When the default camera capture settings do not meet special requirements or cause performance problems, we recommend using this method to set the camera capture preference: - * If the resolution or frame rate of the captured raw video data are higher than those set by setVideoEncoderConfiguration, processing video frames requires extra CPU and RAM usage and degrades performance. We recommend setting config as CAPTURER_OUTPUT_PREFERENCE_PERFORMANCE(1) to avoid such problems. - * If you do not need local video preview or are willing to sacrifice preview quality, we recommend setting config as CAPTURER_OUTPUT_PREFERENCE_PERFORMANCE(1) to optimize CPU and RAM usage. - * If you want better quality for the local video preview, we recommend setting config as CAPTURER_OUTPUT_PREFERENCE_PREVIEW(2). - * - * This method will set the camera capture preference. - * - * @param config {@link CameraCapturerConfiguration} - * - * @returns Promise<{success, value}> - */ - static setCameraCapturerConfiguration(config) { - return Agora.setCameraCapturerConfiguration(config); - } -} -RtcEngine.eventTypes = new Set(); -exports.default = RtcEngine; -//# sourceMappingURL=RtcEngine.native.js.map \ No newline at end of file diff --git a/lib/RtcEngine.native.js.map b/lib/RtcEngine.native.js.map deleted file mode 100644 index e2a1a2aed..000000000 --- a/lib/RtcEngine.native.js.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"file":"RtcEngine.native.js","sourceRoot":"","sources":["../src/RtcEngine.native.ts"],"names":[],"mappings":";;AAAA,+CAIsB;AA0BtB,MAAM,EAAE,KAAK,EAAE,GAAG,4BAAa,CAAC;AAChC,MAAM,iBAAiB,GAAG,IAAI,iCAAkB,C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;;;;OAMG;IACH,MAAM,CAAC,qBAAqB;QACxB,OAAO,KAAK,CAAC,qBAAqB,EAAE,CAAC;IACzC,CAAC;IAED;;;;;;;;;;OAUG;IACH,MAAM,CAAC,qBAAqB,CAAC,GAAW,EAAE,WAAmB;QACzD,OAAO,KAAK,CAAC,qBAAqB,CAAC,GAAG,EAAE,WAAW,CAAC,CAAC;IACzD,CAAC;IAED;;;;;;;;;;;;;OAaG;IACH,MAAM,CAAC,yBAAyB,CAAC,QAAgB;QAC7C,OAAO,KAAK,CAAC,yBAAyB,CAAC,QAAQ,CAAC,CAAA;IACpD,CAAC;IAED;;;;;;;;;;;;;;OAcG;IACH,MAAM,CAAC,8BAA8B,CAAC,MAAmC;QACrE,OAAO,KAAK,CAAC,8BAA8B,CAAC,MAAM,CAAC,CAAC;IACxD,CAAC;;AAtyCc,oBAAU,GAAgB,IAAI,GAAG,EAAU,CAAC;AA4yC/D,kBAAe,SAAS,CAAC"} \ No newline at end of file diff --git a/lib/index.js b/lib/index.js deleted file mode 100644 index e090962af..000000000 --- a/lib/index.js +++ /dev/null @@ -1,7 +0,0 @@ -"use strict"; -Object.defineProperty(exports, "__esModule", { value: true }); -var AgoraView_native_1 = require("./AgoraView.native"); -exports.AgoraView = AgoraView_native_1.default; -var RtcEngine_native_1 = require("./RtcEngine.native"); -exports.RtcEngine = RtcEngine_native_1.default; -//# sourceMappingURL=index.js.map \ No newline at end of file diff --git a/lib/index.js.map b/lib/index.js.map deleted file mode 100644 index 3659be366..000000000 --- a/lib/index.js.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";;AAAA,uDAAwD;AAAhD,uCAAA,OAAO,CAAa;AAC5B,uDAAwD;AAAhD,uCAAA,OAAO,CAAa"} \ No newline at end of file diff --git a/package.json b/package.json index e8e440fef..aaede0df8 100644 --- a/package.json +++ b/package.json @@ -4,6 +4,7 @@ "description": "React Native around the Agora RTC SDKs for Android and iOS agora", "summary": "agora native sdk for react-native", "main": "lib/index.js", + "types": "lib/index.d.ts", "scripts": { "pu": "npm publish", "test": "echo \"Error: no test specified\" && exit 1", @@ -51,9 +52,6 @@ "typedoc": "^0.14.2", "typescript": "^3.2.4" }, - "types": [ - "./types.d.ts" - ], "jest": { "preset": "react-native", "moduleFileExtensions": [ diff --git a/src/AgoraView.native.tsx b/src/AgoraView.native.tsx index b93d372df..23a2739de 100644 --- a/src/AgoraView.native.tsx +++ b/src/AgoraView.native.tsx @@ -5,11 +5,11 @@ import { import { AgoraViewProps -} from "./types.d"; +} from "./types"; /** * Import RCTAgoraView from native binding. - * + * * This @object is used to bridge native layer between react layer. */ @@ -17,15 +17,15 @@ const RCTAgoraView = requireNativeComponent("RCTAgoraView"); /** * AgoraView is the render layer for rendering video stream - * + * * This class is used to rendering native sdk stream - * + * * @props {@link AgoraViewProps} */ export default class AgoraView extends React.Component { /** * render - * + * * It would render view for VideoStream */ public render(): JSX.Element { @@ -36,7 +36,7 @@ export default class AgoraView extends React.Component { /** * getHTMLProps - * + * * get agora view props */ private getHTMLProps(): AgoraViewProps { diff --git a/src/RtcEngine.native.ts b/src/RtcEngine.native.ts index 56a1f18c5..4dd54b15f 100644 --- a/src/RtcEngine.native.ts +++ b/src/RtcEngine.native.ts @@ -25,7 +25,7 @@ import { BeautyOption, LastmileProbeConfig, CameraCapturerConfiguration -} from "./types.d"; +} from "./types"; const { Agora } = NativeModules; @@ -33,9 +33,9 @@ const AgoraEventEmitter = new NativeEventEmitter(Agora); /** * RtcEngine is the javascript object for control agora native sdk through react native bridge. - * + * * You can use the RtcEngine methods to create {@link init} - * + * * Other methods of the RtcEngine object serve for agora native sdk and set up error logging. */ class RtcEngine { @@ -44,7 +44,7 @@ class RtcEngine { /** * Creates a RtcEngine Object internal. - * + * * This method creates and start event observer. You should call this method once. * @example `RtcEngine.init(option)` * @param options Defines the property of the client, see {@link Option} for details. @@ -55,24 +55,24 @@ class RtcEngine { /** * join specified channel - * + * * This method joins and begin rendering the video stream. when join succeeds. * Otherwise, it will invoke error by the event - * @param channelName - * @param uid - * @param token - * @param info + * @param channelName + * @param uid + * @param token + * @param info */ public static joinChannel(channelName: string, uid?: number, token?: string, info?: Object): void { return Agora.joinChannel({channelName, uid, token, info}); } - + /** * add event listener - * + * * This method subscribes specified eventType and run listener. You should call this method at first. * @param eventType - * @param listener + * @param listener */ public static on(eventType: string, listener: (...args: any[]) => any) { this.eventTypes.add(eventType); @@ -81,9 +81,9 @@ class RtcEngine { /** * remove event listeners - * + * * This method unsubscribes specified eventType related all listeners. You should call this method when you want to unsubscribe some eventType. - * @param eventType + * @param eventType */ public static off(eventType: string) { AgoraEventEmitter.removeAllListeners(eventType); @@ -92,10 +92,10 @@ class RtcEngine { /** * remove all events listeners - * + * * This method unsubscribes all eventTypes related listeners. - * - * @param token + * + * @param token */ public static removeAllListeners() { for (let eventType of this.eventTypes) { @@ -106,7 +106,7 @@ class RtcEngine { /** * renew token - * + * * This method renews a new token. * @param token */ @@ -116,9 +116,9 @@ class RtcEngine { /** * enable websdk interoperability - * + * * This method used to enable websdk interoperability, so that it can connect with agora websdk apps. - * + * * @param enabled * @returns Promise<{success, value}> */ @@ -128,7 +128,7 @@ class RtcEngine { /** * get agora native sdk connection state - * + * * This method gets agora native sdk connection state * @returns Promise<{success: true, state: (connection state)}> */ @@ -138,7 +138,7 @@ class RtcEngine { /** * change the client role - * + * * This method changes the client of role. * @param role (audience: 0, host: 1) */ @@ -148,10 +148,10 @@ class RtcEngine { /** * leave channel - * + * * This method leaves the joined channel, then your video view will not render ever. * You should call it, when you dont need render video stream. - * + * * @returns Promise<{success, value}> */ public static leaveChannel(): Promise { @@ -160,10 +160,10 @@ class RtcEngine { /** * destroy - * + * * This method stops event subscribe and destroy the RtcEngine instance's. * You should call it, when you want to destroy the engine. - * + * * @returns Promise<{success, value}> */ public static destroy(): Promise { @@ -172,7 +172,7 @@ class RtcEngine { /** * show local video - * + * * This method calls native sdk render canvas for local video. * @param options {@link VideoOption} */ @@ -183,7 +183,7 @@ class RtcEngine { /** * show remote video - * + * * This method calls native sdk render canvas for remote video. * @param options {@link VideoOption} */ @@ -193,7 +193,7 @@ class RtcEngine { /** * set local video render mode - * + * * This method calls native sdk render mode for local video. * @param mode */ @@ -203,9 +203,9 @@ class RtcEngine { /** * set the specified remote video render mode - * + * * This method calls native sdk render mode for the specified remote video. - * + * * @param uid * @param mode */ @@ -215,7 +215,7 @@ class RtcEngine { /** * start video preview - * + * * This method start video preview for video. */ public static startPreview() { @@ -225,7 +225,7 @@ class RtcEngine { /** * stop video preview - * + * * This method stops video preview for video. */ public static stopPreview() { @@ -234,7 +234,7 @@ class RtcEngine { /** * set enable speaker phone - * + * * This method set the speaker phone enable or disable by pass boolean parameter. * @param enabled */ @@ -244,7 +244,7 @@ class RtcEngine { /** * set default audio speaker - * + * * This method set the default audio speaker enable or disable by pass boolean parameter. * @param enabled */ @@ -255,9 +255,9 @@ class RtcEngine { /** * set default mute all remote audio streams - * + * * This method set default mute all remote audio streams enable or not by pass boolean parameter. - * @param enabled + * @param enabled */ public static setDefaultMuteAllRemoteAudioStreams(enabled: boolean) { Agora.setDefaultMuteAllRemoteAudioStreams(enabled); @@ -265,7 +265,7 @@ class RtcEngine { /** * enable video - * + * * This method enables video. */ public static enableVideo() { @@ -274,7 +274,7 @@ class RtcEngine { /** * disable video - * + * * This method disables video. */ public static disableVideo() { @@ -283,27 +283,27 @@ class RtcEngine { /** * enable local video - * + * * This method enables the local video by the boolean parameter. * @param enabled */ public static enableLocalVideo(enabled: boolean) { Agora.enableLocalVideo(enabled); - } + } /** * mute local video stream - * + * * This method mutes video stream by the boolean parameter. * @param muted */ public static muteLocalVideoStream(muted: boolean) { Agora.muteLocalVideoStream(muted); - } + } /** * mute all remote video streams - * + * * This method mutes all remote streams by the boolean parameter. * @param muted */ @@ -313,7 +313,7 @@ class RtcEngine { /** * mute specified remote video stream. - * + * * This method mutes remote video stream by the number of uid and boolean parameter. * @param uid * @param muted @@ -324,7 +324,7 @@ class RtcEngine { /** * set default mute all remote video stream - * + * * This method mutes all remote video stream default by the boolean parameter. * @param muted */ @@ -334,7 +334,7 @@ class RtcEngine { /** * enable audio - * + * * This method enables audio */ public static enableAudio() { @@ -343,7 +343,7 @@ class RtcEngine { /** * disable audio - * + * * This method disables audio */ public static disableAudio() { @@ -352,7 +352,7 @@ class RtcEngine { /** * enable local audio - * + * * This method enables local audio by the boolean parameter. * @param enabled */ @@ -362,7 +362,7 @@ class RtcEngine { /** * mute local audio stream - * + * * This method mutes the local audio stream by muted. * @param muted */ @@ -372,7 +372,7 @@ class RtcEngine { /** * mute all remote audio streams - * + * * This method mutes all remote audio streams by muted */ public static muteAllRemoteAudioStreams(muted: boolean) { @@ -381,7 +381,7 @@ class RtcEngine { /** * mute specified remote audio stream by muted - * + * * This method mutes specified remote audio stream by number uid and boolean muted. * @param uid * @param muted @@ -392,7 +392,7 @@ class RtcEngine { /** * adjust recording signal volume - * + * * This method adjusts recording your signal by volume. * @param volume */ @@ -402,7 +402,7 @@ class RtcEngine { /** * adjust playback signal volume - * + * * This method adjusts playback signal by volume. * @param volume */ @@ -412,7 +412,7 @@ class RtcEngine { /** * enable audio volume indication - * + * * This method enables audio volume by interval and smooth * @param interval * @param smooth @@ -423,9 +423,9 @@ class RtcEngine { /** * create data stream - * + * * This method creates data stream with options - * + * * @param options {@link DataStreamOption} */ public static createDataStream(options: DataStreamOption) { @@ -434,7 +434,7 @@ class RtcEngine { /** * check for mobile phone speaker enabled - * + * * This method checks the phone speaker is enabled * @param callback */ @@ -444,9 +444,9 @@ class RtcEngine { /** * enable in-ear monitor - * + * * This method enables in-ear monitoring by boolean parameter enabled - * + * * @param enabled */ public static enableInEarMonitoring(enabled: boolean) { @@ -455,9 +455,9 @@ class RtcEngine { /** * set in-ear monitoring volume - * + * * This method sets the in-ear-monitoring volume by number parameter volume - * + * * @param volume */ public static setInEarMonitoringVolume(volume: number) { @@ -466,9 +466,9 @@ class RtcEngine { /** * set local voice pitch - * + * * This method sets the local voice pitch by float parameter pitch - * + * * @param pitch */ public static setLocalVoicePitch(pitch: number) { @@ -477,9 +477,9 @@ class RtcEngine { /** * set local voice equalization - * + * * This method set local video equalization of band frequency by enum band number and number of gain - * + * * @param band * @param gain */ @@ -489,9 +489,9 @@ class RtcEngine { /** * set local voice reverb - * + * * This method sets local voice by reverb and value - * @param reverb + * @param reverb * @param value */ public static setLocalVoiceReverb(reverb: number, value: number) { @@ -500,9 +500,9 @@ class RtcEngine { /** * start audio mixing - * + * * This method will start audio mixing by option config - * + * * @param options {@link AudioMixingOption} */ public static startAudioMixing(options: AudioMixingOption) { @@ -511,7 +511,7 @@ class RtcEngine { /** * stop audio mixing - * + * * This methods stops for audio mixing. */ public static stopAudioMixing() { @@ -520,7 +520,7 @@ class RtcEngine { /** * pause audio mixing - * + * * This method pauses for audio mixing. */ public static pauseAudioMixing() { @@ -529,7 +529,7 @@ class RtcEngine { /** * resume audio mixing - * + * * This method resumes for audio mixing. */ public static resumeAudioMixing() { @@ -538,7 +538,7 @@ class RtcEngine { /** * adjust audio mixing volume - * + * * This method adjusts audio mixing volume by the volume number parameter * @param volume */ @@ -548,7 +548,7 @@ class RtcEngine { /** * adjust audio mixing playout volume - * + * * This method adjusts audio mixing playout by the volume parameter * @param volume */ @@ -558,7 +558,7 @@ class RtcEngine { /** * adjust audio mixing publish volume - * + * * This method adjusts audio mixing publish by the volume paraemter * @param volume */ @@ -568,7 +568,7 @@ class RtcEngine { /** * get audio mixing duration - * + * * This method gets the audio mixing duration * @returns Promise<{success, value}> */ @@ -578,7 +578,7 @@ class RtcEngine { /** * get audio mixing current position - * + * * This method gets audio mixing current position value. * @returns Promise<{success, value}> */ @@ -588,7 +588,7 @@ class RtcEngine { /** * set audio mixing position - * + * * This method sets audio mixing position by the parameter pos * @param pos */ @@ -598,7 +598,7 @@ class RtcEngine { /** * get effects of volume - * + * * This methods get audio mixing effects volume value. * @returns Promise<{success, value}> */ @@ -608,7 +608,7 @@ class RtcEngine { /** * set effects volume - * + * * This methods set audio mixing effects volume by float parameter. * @param volume * @returns Promise<{success, value}> @@ -619,7 +619,7 @@ class RtcEngine { /** * set volume for playing effects. - * + * * This methods set for playing audio mixing effects * @returns Promise<{success, value}> */ @@ -629,7 +629,7 @@ class RtcEngine { /** * play specified effect for audio mixing - * + * * This methos plays the specified effect of audio mixing file by option config. * @param options {@link PlayEffectOption} * @returns Promise<{success, value}> @@ -640,9 +640,9 @@ class RtcEngine { /** * stop play effect for audio mixing - * + * * This methods stops the specified effect for audio mixing file by soundid. - * @param sounid + * @param sounid * @returns Promise<{success, value}> */ public static stopEffect(soundId: number): Promise { @@ -651,7 +651,7 @@ class RtcEngine { /** * stop play all for effect audio mixing. - * + * * This methods stops all effect audio mixing. * @returns Promise<{success, value}> */ @@ -661,7 +661,7 @@ class RtcEngine { /** * preload effect for audio mixing file. - * + * * This methods preloads the specified audio mixing file to memory by the soundid * @param soundid * @param filepath @@ -670,10 +670,10 @@ class RtcEngine { public static preloadEffect(soundId: number, filepath: string): Promise { return Agora.preloadEffect(soundId, filepath); } - + /** * unload effect - * + * * This methods unload the already loaded audio mixing file from memory by the soundid. * @param soundid * @returns Promise<{success, value}> @@ -684,7 +684,7 @@ class RtcEngine { /** * pause the specified effect for audio mixing by soundid - * + * * This method pauses the specified effect for audio mixing by soundid. * @param soundid * @returns Promise<{success, value}> @@ -695,7 +695,7 @@ class RtcEngine { /** * pause all effects for audio mixing - * + * * This method pause all effects for audio mixing. * @param soundid * @returns Promise<{success, value}> @@ -706,7 +706,7 @@ class RtcEngine { /** * resume audio mixing effect by the specified soundid - * + * * This method resumes audio mixing effect by the specified soundid * @param soundid * @returns Promise<{success, value}> @@ -717,7 +717,7 @@ class RtcEngine { /** * resume all audio mixing effects. - * + * * This method resumes all audio mixing effects. * @returns Promise<{success, value}> */ @@ -727,7 +727,7 @@ class RtcEngine { /** * start audio recording by quality - * + * * This method start audio recording by quality config * @param options {@link AudioRecordingOption} * @returns Promise<{success, value}> @@ -738,7 +738,7 @@ class RtcEngine { /** * stop audio recording - * + * * This method stops audio recording. * @returns Promise<{success, value}> */ @@ -748,7 +748,7 @@ class RtcEngine { /** * set audio session operation restriction - * + * * The SDK and the app can both configure the audio session by default. The app may occasionally use other apps or third-party components to manipulate the audio session and restrict the SDK from doing so. This method allows the app to restrict the SDK’s manipulation of the audio session. * You can call this method at any time to return the control of the audio sessions to the SDK. * This method restricts the SDK’s manipulation of the audio session. Any operation to the audio session relies solely on the app, other apps, or third-party components. @@ -762,7 +762,7 @@ class RtcEngine { /** * @deprecated * start echo test - * + * * This method launches an audio call test to determine whether the audio devices (for example, headset and speaker) and the network connection are working properly. * @returns Promise<{success, value}> */ @@ -772,7 +772,7 @@ class RtcEngine { /** * stop echo test - * + * * This method stop launched an audio call test. * @returns Promise<{success, value}> */ @@ -782,9 +782,9 @@ class RtcEngine { /** * enable lastmile test - * + * * This method enables the network connection qualit test. - * + * * @returns Promise<{success, value}> */ public static enableLastmileTest(): Promise { @@ -793,9 +793,9 @@ class RtcEngine { /** * disable lastmile test - * + * * This method disable the network connection qualit test. - * + * * @returns Promise<{success, value}> */ public static disableLastmileTest(): Promise { @@ -804,9 +804,9 @@ class RtcEngine { /** * set recording audio frame parameters - * + * * This method Sets the audio recording format for the audioFrame callback. - * + * * @param options {@link RecordingAudioFrameOption} * @returns Promise<{success, value}> */ @@ -816,9 +816,9 @@ class RtcEngine { /** * set playback audio frame parameters - * + * * This method Sets the audio frame format for the playbackFrame callback. - * + * * @param options {@link AudioFrameOption} * @returns Promise<{success, value}> */ @@ -828,9 +828,9 @@ class RtcEngine { /** * set mixed audio frame parameters - * + * * This method Sets the audio frame format for the mixedAudioFrame callback. - * + * * @param options {@link MixedAudioFrameOption} * @returns Promise<{success, value}> */ @@ -840,7 +840,7 @@ class RtcEngine { /** * add video watermark - * + * * This method adds video watermark to the local video. * * @param options {@link ImageOption} @@ -852,9 +852,9 @@ class RtcEngine { /** * clear video watermarks - * + * * This method removes the watermark image from the video stream added by addVideoWatermark. - * + * * @returns Promise<{success, value}> */ public static removclearVideoWatermarkse(): Promise { @@ -863,9 +863,9 @@ class RtcEngine { /** * set local publish fallback - * + * * This method sets the fallback option for the locally published video stream based on the network conditions. - * + * * @param option {0, 1, 2} [more details](https://docs.agora.io/en/Video/API%20Reference/java/classio_1_1agora_1_1rtc_1_1_constants.html#a3e453c93766e783a7e5eca05b1776238) * @returns Promise<{success, value}> */ @@ -875,9 +875,9 @@ class RtcEngine { /** * set remote publish fallback - * + * * This method sets the fallback option for the remotely subscribed video stream based on the network conditions. - * + * * @param option {0, 1, 2} [more details](https://docs.agora.io/en/Video/API%20Reference/java/classio_1_1agora_1_1rtc_1_1_constants.html#a3e453c93766e783a7e5eca05b1776238) * @returns Promise<{success, value}> */ @@ -887,9 +887,9 @@ class RtcEngine { /** * enable dual stream mode - * + * * This method enables the dual stream by parameter mode. - * + * * @param enabled * @returns Promise<{success, value}> */ @@ -899,9 +899,9 @@ class RtcEngine { /** * set remote video stream type - * + * * This method sets the remote video stream type by uid and streamType. - * + * * @param options {@link VideoStreamOption} * @returns Promise<{success, value}> */ @@ -911,9 +911,9 @@ class RtcEngine { /** * set remote default video stream type - * + * * This method sets the default video stream type. - * + * * @param options {@link DefaultVideoStreamOption} * @returns Promise<{success, value}> */ @@ -923,9 +923,9 @@ class RtcEngine { /** * add inject stream url - * + * * This method injects an online media stream to a live broadcast. - * + * * @param options {@link InjectStreamOption} * @returns Promise<{success, value}> */ @@ -935,9 +935,9 @@ class RtcEngine { /** * remove inject stream url - * + * * This method removes stream by addInjectsStreamUrl. - * + * * @param options {@link RemoveInjectStreamOption} * @returns Promise<{success, value}> */ @@ -947,12 +947,12 @@ class RtcEngine { /** * @deprecated - * set video quality - * + * set video quality + * * This method sets the preferences for the video quality. (Live broadcast only). - * + * * @param quality boolean - * @returns Promise<{success, value}> + * @returns Promise<{success, value}> */ // public static setVideoQualityParameters(quality: boolean): Promise { // return Agora.setVideoQualityParameters(quality); @@ -960,9 +960,9 @@ class RtcEngine { /** * set local video mirror mode - * + * * This method sets local video mirror mode - * + * * @param mode * @returns Promise<{success, value}> */ @@ -972,10 +972,10 @@ class RtcEngine { /** * switch camera - * + * * This method switches camera between front and rear. - * - * @returns Promise<{success, value}> + * + * @returns Promise<{success, value}> */ public static switchCamera(): Promise { return Agora.switchCamera(); @@ -983,9 +983,9 @@ class RtcEngine { /** * is camera zoom supported - * + * * This method checks whether the camera zoom function is supported. - * + * * @returns Promise<{success, value}> */ public static isCameraZoomSupported(): Promise { @@ -994,9 +994,9 @@ class RtcEngine { /** * is camera torch supported - * + * * This method checks whether the camera flash function is supported. - * + * * @returns Promise<{success, value}> */ public static isCameraTorchSupported(): Promise { @@ -1005,9 +1005,9 @@ class RtcEngine { /** * is camera focus supported - * + * * This method checks whether the camera mannual focus function is supported. - * + * * @returns Promise<{success, value}> */ public static isCameraFocusSupported(): Promise { @@ -1016,9 +1016,9 @@ class RtcEngine { /** * is camera exposure position supported - * + * * This method checks whether the camera mannual exposure function is supported. - * + * * @returns Promise<{success, value}> */ public static isCameraExposurePositionSupported(): Promise { @@ -1027,9 +1027,9 @@ class RtcEngine { /** * is camera auto focus face mode supported - * + * * This method checks whether the camera mannual auto-face focus function is supported. - * + * * @returns Promise<{success, value}> */ public static isCameraAutoFocusFaceModeSupported(): Promise { @@ -1038,9 +1038,9 @@ class RtcEngine { /** * set camera zoom ratio - * + * * This method sets the camera zoom ratio. - * + * * @param zoomFactor * @returns Promise<{success, value}> */ @@ -1050,9 +1050,9 @@ class RtcEngine { /** * get camera max zoom ratio - * + * * This method gets the camera maximum zoom ratio. - * + * * @notice Android Only * @returns Promise<{success, value}> */ @@ -1062,9 +1062,9 @@ class RtcEngine { /** * set camera focus position in preview - * + * * This method sets the mannual focus position. - * + * * @param options {@link PositionOption} * @returns Promise<{success, value}> */ @@ -1074,9 +1074,9 @@ class RtcEngine { /** * set camera exposure position - * + * * This method sets the mannual exposure position. - * + * * @param options {@link PositionOption} * @returns Promise<{success, value}> */ @@ -1086,11 +1086,11 @@ class RtcEngine { /** * set camera torch on - * + * * This method enables the camera flash function. - * + * * @param enabled - * @returns Promise<{success, value}> + * @returns Promise<{success, value}> */ public static setCameraTorchOn(enabled: boolean): Promise { return Agora.setCameraTorchOn(enabled); @@ -1098,9 +1098,9 @@ class RtcEngine { /** * set enable auto focus face mode - * + * * This method enables auto-focus face mode function. - * + * * @param enabled boolean * @returns Promise<{success, value}> */ @@ -1109,10 +1109,10 @@ class RtcEngine { } /** - * get call id - * + * get call id + * * This method is used to get call id. - * + * * @returns Promise<{success, value}> */ public static getCallId(): Promise { @@ -1121,7 +1121,7 @@ class RtcEngine { /** * set log file and log filter - * + * * This method sets the log file generated path and specified the log level. * * @param filepath string @@ -1132,14 +1132,14 @@ class RtcEngine { public static setLog(filepath: string, level: number, maxfileSize: number): Promise { return Agora.setLog(filepath, level, maxfileSize) } - + /** * send stream message - * + * * This method sends stream message by specified uid - * + * * @param uid - * @param data + * @param data * @returns Promise<{success, value}> */ public static sendMessage(streamID: number, data: any, reliable: boolean, ordered: boolean): Promise { @@ -1148,9 +1148,9 @@ class RtcEngine { /** * add publish stream url - * + * * This method add publish stream by option. - * + * * @param options {@link PublishStreamOption} * @returns Promise<{success, value}> */ @@ -1160,9 +1160,9 @@ class RtcEngine { /** * remove publish stream url - * + * * This method remove publish stream by options. - * + * * @param options {@link RemovePublishStreamOption} * @returns Promise<{success, value}> */ @@ -1172,9 +1172,9 @@ class RtcEngine { /** * set live transcoding - * + * * This method sets the video layout and audio settings for CDN live. - * + * * @param options {@link LiveTranscoding} * @returns Promise<{success, value}> */ @@ -1184,9 +1184,9 @@ class RtcEngine { /** * get sdk version - * + * * This method gets the sdk version details and passed it into callback function - * + * * @param callback to handle resolve from getSdkVersion * @param errorHandler to handle reject error from getSdkVersion */ @@ -1196,9 +1196,9 @@ class RtcEngine { /** * mute local audio stream - * + * * This method sends/stops sending the local audio. - * + * * @param enabled */ @@ -1208,9 +1208,9 @@ class RtcEngine { /** * video pre-process/post-process - * + * * This method enables/disables image enhancement and sets the options. - * + * * @param enable boolean * @param options {@link BeautyOptions} * @returns Promise<{success, value}> @@ -1221,9 +1221,9 @@ class RtcEngine { /** * set local voice change - * + * * This method changes local speaker voice with voiceChanger - * + * * @param voiceChanger integer * @voiceChanger value ranges [ * 0: "The original voice", @@ -1242,9 +1242,9 @@ class RtcEngine { /** * set the preset local voice reverberation effect. - * + * * This method sets the preset local voice reverberation effect. - * + * * @param preset integer * @returns Promise<{success, value}> */ @@ -1254,9 +1254,9 @@ class RtcEngine { /** * control stereo panning for remote users - * + * * This method enables/disables stereo panning for remote users. - * + * * @param enabled boolean * @returns Promise<{success, value}> */ @@ -1266,12 +1266,12 @@ class RtcEngine { /** * set the sound position of a remote user - * + * * This method sets the sound position of a remote user by uid - * + * * @param uid number | The ID of the remote user * @param pan float | The sound position of the remote user. The value ranges from -1.0 to 1.0 - * @pan + * @pan * 0.0: the remote sound comes from the front. * -1.0: the remote sound comes from the left. * 1.0: the remote sound comes from the right. @@ -1286,9 +1286,9 @@ class RtcEngine { * start the lastmile probe test * * This method start the last-mile network probe test before joining a channel to get the uplink and downlink last-mile network statistics, including the bandwidth, packet loss, jitter, and round-trip time (RTT). - * + * * @param config LastmileProbeConfig {@link LastmileProbeConfig} - * + * * @event onLastmileQuality: the SDK triggers this callback within two seconds depending on the network conditions. This callback rates the network conditions with a score and is more closely linked to the user experience. * @event onLastmileProbeResult: the SDK triggers this callback within 30 seconds depending on the network conditions. This callback returns the real-time statistics of the network conditions and is more objective. * @returns Promise<{success, value}> @@ -1301,7 +1301,7 @@ class RtcEngine { * stop the lastmile probe test * * This method stop the lastmile probe test. - * + * * @returns Promise<{success, value}> */ static stopLastmileProbeTest(): Promise { @@ -1310,13 +1310,13 @@ class RtcEngine { /** * sets the priority of a remote user's media stream. - * + * * note: Use this method with the setRemoteSubscribeFallbackOption method. If the fallback function is enabled for a subscribed stream, the SDK ensures the high-priority user gets the best possible stream quality. - * + * * This method sets the priority of a remote user's media stream. * @param uid number * @param userPriority number | The value range is [50 is "user's priority is hgih", 100 is "the default user's priority is normal"] - * + * * @returns Promise<{success, value}> */ static setRemoteUserPriority(uid: number, userPrority: number): Promise { @@ -1325,16 +1325,16 @@ class RtcEngine { /** * start an audio call test. - * + * * note: * Call this method before joining a channel. * After calling this method, call the stopEchoTest method to end the test. Otherwise, the app cannot run the next echo test, or call the joinchannel method. * In the Live-broadcast profile, only a host can call this method. * This method will start an audio call test with interval parameter. * In the audio call test, you record your voice. If the recording plays back within the set time interval, the audio devices and the network connection are working properly. - * + * * @param interval number - * + * * @returns Promise<{success, value}> */ static startEchoTestWithInterval(interval: number): Promise { @@ -1349,11 +1349,11 @@ class RtcEngine { * If the resolution or frame rate of the captured raw video data are higher than those set by setVideoEncoderConfiguration, processing video frames requires extra CPU and RAM usage and degrades performance. We recommend setting config as CAPTURER_OUTPUT_PREFERENCE_PERFORMANCE(1) to avoid such problems. * If you do not need local video preview or are willing to sacrifice preview quality, we recommend setting config as CAPTURER_OUTPUT_PREFERENCE_PERFORMANCE(1) to optimize CPU and RAM usage. * If you want better quality for the local video preview, we recommend setting config as CAPTURER_OUTPUT_PREFERENCE_PREVIEW(2). - * + * * This method will set the camera capture preference. - * + * * @param config {@link CameraCapturerConfiguration} - * + * * @returns Promise<{success, value}> */ static setCameraCapturerConfiguration(config: CameraCapturerConfiguration): Promise { diff --git a/src/types.d.ts b/src/types.ts similarity index 99% rename from src/types.d.ts rename to src/types.ts index 9665ccffc..3c566cbbf 100644 --- a/src/types.d.ts +++ b/src/types.ts @@ -1,6 +1,5 @@ import { View, ViewProps } from 'react-native'; -declare module "IAgora" /** * VideoEncoderConfig details @@ -45,8 +44,8 @@ export interface Option { /** * VoiceDecorator is decorate local audio voice - * - * @property type: string | the range values ['changer' | 'reverbPreset'] This property is the identifier for audio voice decorator + * + * @property type: string | the range values ['changer' | 'reverbPreset'] This property is the identifier for audio voice decorator * @property value: number | the value for voice parameter option. * type 'reverbPreset' range values: [0 is "off", 1 is "popular", 2 is "rnb", 3 is "rock", 4 is "hiphop", 5 is "vocal concert", 6 is "KTV", 7 is "studio"] * type 'changer' range values: [0 is "off", 1 is "old man", 2 is "baby boy", 3 is "baby girl", 4 is "zhubajie", 5 is "ethereal", 6 is "hulk"] @@ -267,4 +266,4 @@ export interface LastmileProbeConfig { */ export interface CameraCapturerConfiguration { preference: number -} \ No newline at end of file +} diff --git a/tsconfig.json b/tsconfig.json index d8ce9b121..e8668a1e6 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -12,6 +12,7 @@ "outDir": "./lib", "module": "commonjs", "strict": true, + "declaration": true, "allowSyntheticDefaultImports": true, "esModuleInterop": true, "lib": ["es2015"] diff --git a/yarn.lock b/yarn.lock index cfe775d41..a29adc00a 100644 --- a/yarn.lock +++ b/yarn.lock @@ -647,11 +647,64 @@ lodash "^4.17.10" to-fast-properties "^2.0.0" +"@types/events@*": + version "3.0.0" + resolved "https://registry.yarnpkg.com/@types/events/-/events-3.0.0.tgz#2862f3f58a9a7f7c3e78d79f130dd4d71c25c2a7" + integrity sha512-EaObqwIvayI5a8dCzhFrjKzVwKLxjoG9T6Ppd5CEo07LRKfQ8Yokw54r5+Wq7FaBQ+yXRvQAYPrHwya1/UFt9g== + +"@types/fs-extra@^5.0.3": + version "5.0.5" + resolved "https://registry.yarnpkg.com/@types/fs-extra/-/fs-extra-5.0.5.tgz#080d90a792f3fa2c5559eb44bd8ef840aae9104b" + integrity sha512-w7iqhDH9mN8eLClQOYTkhdYUOSpp25eXxfc6VbFOGtzxW34JcvctH2bKjj4jD4++z4R5iO5D+pg48W2e03I65A== + dependencies: + "@types/node" "*" + +"@types/glob@*": + version "7.1.1" + resolved "https://registry.yarnpkg.com/@types/glob/-/glob-7.1.1.tgz#aa59a1c6e3fbc421e07ccd31a944c30eba521575" + integrity sha512-1Bh06cbWJUHMC97acuD6UMG29nMt0Aqz1vF3guLfG+kHHJhy3AyohZFFxYk2f7Q1SQIrNwvncxAE0N/9s70F2w== + dependencies: + "@types/events" "*" + "@types/minimatch" "*" + "@types/node" "*" + +"@types/handlebars@^4.0.38": + version "4.1.0" + resolved "https://registry.yarnpkg.com/@types/handlebars/-/handlebars-4.1.0.tgz#3fcce9bf88f85fe73dc932240ab3fb682c624850" + integrity sha512-gq9YweFKNNB1uFK71eRqsd4niVkXrxHugqWFQkeLRJvGjnxsLr16bYtcsG4tOFwmYi0Bax+wCkbf1reUfdl4kA== + dependencies: + handlebars "*" + +"@types/highlight.js@^9.12.3": + version "9.12.3" + resolved "https://registry.yarnpkg.com/@types/highlight.js/-/highlight.js-9.12.3.tgz#b672cfaac25cbbc634a0fd92c515f66faa18dbca" + integrity sha512-pGF/zvYOACZ/gLGWdQH8zSwteQS1epp68yRcVLJMgUck/MjEn/FBYmPub9pXT8C1e4a8YZfHo1CKyV8q1vKUnQ== + "@types/jest@^23.3.13": version "23.3.14" resolved "http://registry.npm.taobao.org/@types/jest/download/@types/jest-23.3.14.tgz#37daaf78069e7948520474c87b80092ea912520a" integrity sha1-N9qveAaeeUhSBHTIe4AJLqkSUgo= +"@types/lodash@^4.14.110": + version "4.14.123" + resolved "https://registry.yarnpkg.com/@types/lodash/-/lodash-4.14.123.tgz#39be5d211478c8dd3bdae98ee75bb7efe4abfe4d" + integrity sha512-pQvPkc4Nltyx7G1Ww45OjVqUsJP4UsZm+GWJpigXgkikZqJgRm4c48g027o6tdgubWHwFRF15iFd+Y4Pmqv6+Q== + +"@types/marked@^0.4.0": + version "0.4.2" + resolved "https://registry.yarnpkg.com/@types/marked/-/marked-0.4.2.tgz#64a89e53ea37f61cc0f3ee1732c555c2dbf6452f" + integrity sha512-cDB930/7MbzaGF6U3IwSQp6XBru8xWajF5PV2YZZeV8DyiliTuld11afVztGI9+yJZ29il5E+NpGA6ooV/Cjkg== + +"@types/minimatch@*", "@types/minimatch@3.0.3": + version "3.0.3" + resolved "https://registry.yarnpkg.com/@types/minimatch/-/minimatch-3.0.3.tgz#3dca0e3f33b200fc7d1139c0cd96c1268cadfd9d" + integrity sha512-tHq6qdbT9U1IRSGf14CL0pUlULksvY9OZ+5eEgl1N7t+OA3tGvNpxJCzuKQlsNgCVwbAs670L1vcVQi8j9HjnA== + +"@types/node@*": + version "11.13.7" + resolved "https://registry.yarnpkg.com/@types/node/-/node-11.13.7.tgz#85dbb71c510442d00c0631f99dae957ce44fd104" + integrity sha512-suFHr6hcA9mp8vFrZTgrmqW2ZU3mbWsryQtQlY/QvwTISCw7nw/j+bCQPPohqmskhmqa5wLNuMHTTsc+xf1MQg== + "@types/prop-types@*": version "15.5.9" resolved "http://registry.npm.taobao.org/@types/prop-types/download/@types/prop-types-15.5.9.tgz#f2d14df87b0739041bc53a7d75e3d77d726a3ec0" @@ -680,6 +733,14 @@ "@types/prop-types" "*" csstype "^2.2.0" +"@types/shelljs@^0.8.0": + version "0.8.5" + resolved "https://registry.yarnpkg.com/@types/shelljs/-/shelljs-0.8.5.tgz#1e507b2f6d1f893269bd3e851ec24419ef9beeea" + integrity sha512-bZgjwIWu9gHCjirKJoOlLzGi5N0QgZ5t7EXEuoqyWCHTuSddURXo3FOBYDyRPNOWzZ6NbkLvZnVkn483Y/tvcQ== + dependencies: + "@types/glob" "*" + "@types/node" "*" + abab@^2.0.0: version "2.0.0" resolved "http://registry.npm.taobao.org/abab/download/abab-2.0.0.tgz#aba0ab4c5eee2d4c79d3487d85450fb2376ebb0f" @@ -2349,6 +2410,15 @@ fs-extra@^1.0.0: jsonfile "^2.1.0" klaw "^1.0.0" +fs-extra@^7.0.0: + version "7.0.1" + resolved "https://registry.yarnpkg.com/fs-extra/-/fs-extra-7.0.1.tgz#4f189c44aa123b895f722804f55ea23eadc348e9" + integrity sha512-YJDaCJZEnBmcbw13fvdAM9AwNOJwOzrE4pqMqBq5nFiEqXUqHwlK4B+3pUw6JNvfSPtX05xFHtYy/1ni01eGCw== + dependencies: + graceful-fs "^4.1.2" + jsonfile "^4.0.0" + universalify "^0.1.0" + fs-minipass@^1.2.5: version "1.2.5" resolved "http://registry.npm.taobao.org/fs-minipass/download/fs-minipass-1.2.5.tgz#06c277218454ec288df77ada54a03b8702aacb9d" @@ -2443,7 +2513,7 @@ glob-parent@^2.0.0: dependencies: is-glob "^2.0.0" -glob@^7.0.3, glob@^7.1.1, glob@^7.1.2, glob@^7.1.3: +glob@^7.0.0, glob@^7.0.3, glob@^7.1.1, glob@^7.1.2, glob@^7.1.3: version "7.1.3" resolved "http://registry.npm.taobao.org/glob/download/glob-7.1.3.tgz#3960832d3f1574108342dafd3a67b332c0969df1" integrity sha1-OWCDLT8VdBCDQtr9OmezMsCWnfE= @@ -2483,6 +2553,17 @@ growly@^1.3.0: resolved "http://registry.npm.taobao.org/growly/download/growly-1.3.0.tgz#f10748cbe76af964b7c96c93c6bcc28af120c081" integrity sha1-8QdIy+dq+WS3yWyTxrzCivEgwIE= +handlebars@*, handlebars@^4.0.6: + version "4.1.2" + resolved "https://registry.yarnpkg.com/handlebars/-/handlebars-4.1.2.tgz#b6b37c1ced0306b221e094fc7aca3ec23b131b67" + integrity sha512-nvfrjqvt9xQ8Z/w0ijewdD/vvWDTOweBUm96NTr66Wfvo1mJenBLwcYmPs3TIBP5ruzYGD7Hx/DaM9RmhroGPw== + dependencies: + neo-async "^2.6.0" + optimist "^0.6.1" + source-map "^0.6.1" + optionalDependencies: + uglify-js "^3.1.4" + handlebars@^4.0.11: version "4.1.0" resolved "http://registry.npm.taobao.org/handlebars/download/handlebars-4.1.0.tgz#0d6a6f34ff1f63cecec8423aa4169827bf787c3a" @@ -2567,6 +2648,11 @@ has@^1.0.1, has@^1.0.3: dependencies: function-bind "^1.1.1" +highlight.js@^9.13.1: + version "9.15.6" + resolved "https://registry.yarnpkg.com/highlight.js/-/highlight.js-9.15.6.tgz#72d4d8d779ec066af9a17cb14360c3def0aa57c4" + integrity sha512-zozTAWM1D6sozHo8kqhfYgsac+B+q0PmsjXeyDrYIHHcBN0zTVT66+s2GW1GZv7DbyaROdLXKdabwS/WqPyIdQ== + home-or-tmp@^2.0.0: version "2.0.0" resolved "http://registry.npm.taobao.org/home-or-tmp/download/home-or-tmp-2.0.0.tgz#e36c3f2d2cae7d746a857e38d18d5f32a7882db8" @@ -2689,6 +2775,11 @@ inquirer@^3.0.6: strip-ansi "^4.0.0" through "^2.3.6" +interpret@^1.0.0: + version "1.2.0" + resolved "https://registry.yarnpkg.com/interpret/-/interpret-1.2.0.tgz#d5061a6224be58e8083985f5014d844359576296" + integrity sha512-mT34yGKMNceBQUoVn7iCDKDntA7SC6gycMAWzGx1z/CMCTV7b2AAtXlo3nRyHZ1FelRkQbQjprHSYGwzLtkVbw== + invariant@^2.2.2, invariant@^2.2.4: version "2.2.4" resolved "http://registry.npm.taobao.org/invariant/download/invariant-2.2.4.tgz#610f3c92c9359ce1db616e538008d23ff35158e6" @@ -3708,6 +3799,13 @@ jsonfile@^2.1.0: optionalDependencies: graceful-fs "^4.1.6" +jsonfile@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/jsonfile/-/jsonfile-4.0.0.tgz#8771aae0799b64076b76640fca058f9c10e33ecb" + integrity sha1-h3Gq4HmbZAdrdmQPygWPnBDjPss= + optionalDependencies: + graceful-fs "^4.1.6" + jsonify@~0.0.0: version "0.0.0" resolved "http://registry.npm.taobao.org/jsonify/download/jsonify-0.0.0.tgz#2c74b6ee41d93ca51b7b5aaee8f503631d252a73" @@ -3926,6 +4024,11 @@ map-visit@^1.0.0: dependencies: object-visit "^1.0.0" +marked@^0.4.0: + version "0.4.0" + resolved "https://registry.yarnpkg.com/marked/-/marked-0.4.0.tgz#9ad2c2a7a1791f10a852e0112f77b571dce10c66" + integrity sha512-tMsdNBgOsrUophCAFQl0XPe6Zqk/uy9gnue+jIIKhykO51hxyu6uNx7zBPy0+y/WKYVZZMspV9YeXLNdKk+iYw== + math-random@^1.0.1: version "1.0.4" resolved "http://registry.npm.taobao.org/math-random/download/math-random-1.0.4.tgz#5dd6943c938548267016d4e34f057583080c514c" @@ -4226,7 +4329,7 @@ min-document@^2.19.0: dependencies: dom-walk "^0.1.0" -minimatch@^3.0.3, minimatch@^3.0.4: +minimatch@^3.0.0, minimatch@^3.0.3, minimatch@^3.0.4: version "3.0.4" resolved "http://registry.npm.taobao.org/minimatch/download/minimatch-3.0.4.tgz#5166e286457f03306064be5497e8dbb0c3d32083" integrity sha1-UWbihkV/AzBgZL5Ul+jbsMPTIIM= @@ -4345,6 +4448,11 @@ negotiator@0.6.1: resolved "http://registry.npm.taobao.org/negotiator/download/negotiator-0.6.1.tgz#2b327184e8992101177b28563fb5e7102acd0ca9" integrity sha1-KzJxhOiZIQEXeyhWP7XnECrNDKk= +neo-async@^2.6.0: + version "2.6.0" + resolved "https://registry.yarnpkg.com/neo-async/-/neo-async-2.6.0.tgz#b9d15e4d71c6762908654b5183ed38b753340835" + integrity sha512-MFh0d/Wa7vkKO3Y3LlacqAEeHK0mckVqzDieUKTT+KGxi+zIpeVsFxymkIiRpbpDziHc290Xr9A1O4Om7otoRA== + nice-try@^1.0.4: version "1.0.5" resolved "http://registry.npm.taobao.org/nice-try/download/nice-try-1.0.5.tgz#a3378a7696ce7d223e88fc9b764bd7ef1089e366" @@ -4923,6 +5031,11 @@ process@~0.5.1: resolved "http://registry.npm.taobao.org/process/download/process-0.5.2.tgz#1638d8a8e34c2f440a91db95ab9aeb677fc185cf" integrity sha1-FjjYqONML0QKkduVq5rrZ3/Bhc8= +progress@^2.0.0: + version "2.0.3" + resolved "https://registry.yarnpkg.com/progress/-/progress-2.0.3.tgz#7e8cf8d8f5b8f239c1bc68beb4eb78567d572ef8" + integrity sha512-7PiHtLll5LdnKIMw100I+8xJXR5gW2QwWYkT6iJva0bXitZKa/XMrSbdmg3r2Xnaidz9Qumd0VPaMrZlF9V9sA== + promise@^7.1.1: version "7.3.1" resolved "http://registry.npm.taobao.org/promise/download/promise-7.3.1.tgz#064b72602b18f90f29192b8b1bc418ffd1ebd3bf" @@ -5197,6 +5310,13 @@ realpath-native@^1.0.0, realpath-native@^1.0.2: dependencies: util.promisify "^1.0.0" +rechoir@^0.6.2: + version "0.6.2" + resolved "https://registry.yarnpkg.com/rechoir/-/rechoir-0.6.2.tgz#85204b54dba82d5742e28c96756ef43af50e3384" + integrity sha1-hSBLVNuoLVdC4oyWdW70OvUOM4Q= + dependencies: + resolve "^1.1.6" + regenerate-unicode-properties@^7.0.0: version "7.0.0" resolved "http://registry.npm.taobao.org/regenerate-unicode-properties/download/regenerate-unicode-properties-7.0.0.tgz#107405afcc4a190ec5ed450ecaa00ed0cafa7a4c" @@ -5368,6 +5488,13 @@ resolve@1.x, resolve@^1.10.0, resolve@^1.3.2, resolve@^1.5.0, resolve@^1.8.1: dependencies: path-parse "^1.0.6" +resolve@^1.1.6: + version "1.10.1" + resolved "https://registry.yarnpkg.com/resolve/-/resolve-1.10.1.tgz#664842ac960795bbe758221cdccda61fb64b5f18" + integrity sha512-KuIe4mf++td/eFb6wkaPbMDnP6kObCaEtIDuHOUED6MNUo4K670KZUHuuvYPZDxNF0WVLw49n06M2m2dXphEzA== + dependencies: + path-parse "^1.0.6" + restore-cursor@^2.0.0: version "2.0.0" resolved "http://registry.npm.taobao.org/restore-cursor/download/restore-cursor-2.0.0.tgz#9f7ee287f82fd326d4fd162923d62129eee0dfaf" @@ -5565,6 +5692,15 @@ shell-quote@1.6.1, shell-quote@^1.6.1: array-reduce "~0.0.0" jsonify "~0.0.0" +shelljs@^0.8.2: + version "0.8.3" + resolved "https://registry.yarnpkg.com/shelljs/-/shelljs-0.8.3.tgz#a7f3319520ebf09ee81275b2368adb286659b097" + integrity sha512-fc0BKlAWiLpwZljmOvAOTE/gXawtCoNrP5oaY7KIaQbbyHeQVg01pSEuEGvGh3HEdBU4baCD7wQBwADmM/7f7A== + dependencies: + glob "^7.0.0" + interpret "^1.0.0" + rechoir "^0.6.2" + shellwords@^0.1.1: version "0.1.1" resolved "http://registry.npm.taobao.org/shellwords/download/shellwords-0.1.1.tgz#d6b9181c1a48d397324c84871efbcfc73fc0654b" @@ -6088,6 +6224,39 @@ typedarray@^0.0.6: resolved "http://registry.npm.taobao.org/typedarray/download/typedarray-0.0.6.tgz#867ac74e3864187b1d3d47d996a78ec5c8830777" integrity sha1-hnrHTjhkGHsdPUfZlqeOxciDB3c= +typedoc-default-themes@^0.5.0: + version "0.5.0" + resolved "https://registry.yarnpkg.com/typedoc-default-themes/-/typedoc-default-themes-0.5.0.tgz#6dc2433e78ed8bea8e887a3acde2f31785bd6227" + integrity sha1-bcJDPnjti+qOiHo6zeLzF4W9Yic= + +typedoc@^0.14.2: + version "0.14.2" + resolved "https://registry.yarnpkg.com/typedoc/-/typedoc-0.14.2.tgz#769f457f4f9e4bdb8b5f3b177c86b6a31d8c3dc3" + integrity sha512-aEbgJXV8/KqaVhcedT7xG6d2r+mOvB5ep3eIz1KuB5sc4fDYXcepEEMdU7XSqLFO5hVPu0nllHi1QxX2h/QlpQ== + dependencies: + "@types/fs-extra" "^5.0.3" + "@types/handlebars" "^4.0.38" + "@types/highlight.js" "^9.12.3" + "@types/lodash" "^4.14.110" + "@types/marked" "^0.4.0" + "@types/minimatch" "3.0.3" + "@types/shelljs" "^0.8.0" + fs-extra "^7.0.0" + handlebars "^4.0.6" + highlight.js "^9.13.1" + lodash "^4.17.10" + marked "^0.4.0" + minimatch "^3.0.0" + progress "^2.0.0" + shelljs "^0.8.2" + typedoc-default-themes "^0.5.0" + typescript "3.2.x" + +typescript@3.2.x: + version "3.2.4" + resolved "https://registry.yarnpkg.com/typescript/-/typescript-3.2.4.tgz#c585cb952912263d915b462726ce244ba510ef3d" + integrity sha512-0RNDbSdEokBeEAkgNbxJ+BLwSManFy9TeXz8uW+48j/xhEXv1ePME60olyzw2XzUqUBNAYFeJadIqAgNqIACwg== + typescript@^3.2.4: version "3.3.3" resolved "http://registry.npm.taobao.org/typescript/download/typescript-3.3.3.tgz#f1657fc7daa27e1a8930758ace9ae8da31403221" @@ -6157,6 +6326,11 @@ union-value@^1.0.0: is-extendable "^0.1.1" set-value "^0.4.3" +universalify@^0.1.0: + version "0.1.2" + resolved "https://registry.yarnpkg.com/universalify/-/universalify-0.1.2.tgz#b646f69be3942dabcecc9d6639c80dc105efaa66" + integrity sha512-rBJeI5CXAlmy1pV+617WB9J63U6XcazHHF2f2dbJix4XzpUF0RS3Zbj0FGIOCAva5P/d/GBOYaACQ1w+0azUkg== + unpipe@~1.0.0: version "1.0.0" resolved "http://registry.npm.taobao.org/unpipe/download/unpipe-1.0.0.tgz#b2bf4ee8514aae6165b4817829d21b2ef49904ec"