Skip to content

Commit

Permalink
SDK update 4.2.4 and introducing prejoinPagEnabled and disableInviteF…
Browse files Browse the repository at this point in the history
…unctions parameters
  • Loading branch information
fareed069417 committed Mar 14, 2023
1 parent f28cf12 commit ba72605
Show file tree
Hide file tree
Showing 10 changed files with 56 additions and 14 deletions.
14 changes: 9 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ Meet Hour Example project for React Native with APIs
[Meet Hour - 100% free video conference solution](https://meethour.io)
Meet Hour is 100% free video conference solution with End to End Encrypted and many other features such as lobby mode, Donor box & Click&Pledge Connect for fundraising, Video call recording, Youtube Live Stream etc.

### NPM package (Latest version - 3.0.19)
### NPM package (Latest version - 3.0.20)

```
https://www.npmjs.com/package/react-native-meet-hour-sdk
Expand Down Expand Up @@ -389,6 +389,8 @@ const conferenceOptions = {
pcode: '', //Dynamic Password of Conference. Will get from Schedule API & ViewMeeting APIs
audioMuted: false,
videoMuted: false,
prejoinPageEnabled: false, // Make it true to Skip PrejoinPage
disableInviteFunctions: true, // To disable invite functions in Mobile SDK.
};
function App() {
Expand Down Expand Up @@ -630,10 +632,10 @@ allprojects {
```groovy
buildscript {
ext {
buildToolsVersion = "30.0.3"
buildToolsVersion = "33.0.1"
minSdkVersion = 24 // <-- this line
compileSdkVersion = 32
targetSdkVersion = 32
compileSdkVersion = 33
targetSdkVersion = 33
ndkVersion = "20.1.5948944"
}
...
Expand Down Expand Up @@ -672,7 +674,7 @@ buildscript {

## Options

| key | Data type | Default | Description |
| key | Data type | Default | Description |
| ------------ | --------- | ------------------- | --------------------------------------------------------------------------------------------------------------- |
| room | string | required | Room name for Meet Hour |
| serverUrl | string | https://meethour.io | Valid server URL |
Expand All @@ -682,6 +684,8 @@ buildscript {
| audioOnly | boolean | false | Controls whether the participant will join the conference in audio-only mode (no video is sent or recieved) |
| audioMuted | boolean | false | Controls whether the participant will join the conference with the microphone muted |
| videoMuted | boolean | false | Controls whether the participant will join the conference with the camera muted |
| prejoinPageEnabled | boolean | true | Make it true to Skip PrejoinPage
| disableInviteFunctions | boolean | true | To disable invite functions in Mobile SDK
| userInfo | object | {} | Object that contains information about the participant starting the meeting. See [UserInfo](#userinfo) |
| featureFlags | object | {} | Object that contains information about which feature flags should be set. See below for more info. |

Expand Down
10 changes: 5 additions & 5 deletions android/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ buildscript {
}

dependencies {
classpath 'com.android.tools.build:gradle:4.0.1'
classpath 'com.android.tools.build:gradle:7.1.3'
}
}
}
Expand All @@ -18,11 +18,11 @@ def safeExtGet(prop, fallback) {
}

android {
compileSdkVersion safeExtGet('MeetHour_compileSdkVersion', 31)
buildToolsVersion safeExtGet('MeetHour_buildToolsVersion', '29.0.2')
compileSdkVersion safeExtGet('MeetHour_compileSdkVersion', 33)
buildToolsVersion safeExtGet('MeetHour_buildToolsVersion', '33.0.1')
defaultConfig {
minSdkVersion safeExtGet('MeetHour_minSdkVersion', 23)
targetSdkVersion safeExtGet('MeetHour_targetSdkVersion', 31)
targetSdkVersion safeExtGet('MeetHour_targetSdkVersion', 33)
versionCode 1
versionName "1.0"

Expand Down Expand Up @@ -58,7 +58,7 @@ dependencies {
//noinspection GradleDynamicVersion
implementation "com.facebook.react:react-native:+" // From node_modules

implementation ('go.meethour.io.react:meet-hour-sdk:4.2.3') {
implementation ('go.meethour.io.react:meet-hour-sdk:4.2.4') {
transitive = true
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -114,6 +114,14 @@ public void launchMeetHourView(ReadableMap options, Promise onConferenceTerminat
builder.setVideoMuted(options.getBoolean("videoMuted"));
}

if (options.hasKey("prejoinPageEnabled")) {
builder.setPrejoinPageEnabled(options.getBoolean("prejoinPageEnabled"));
}

if (options.hasKey("disableInviteFunctions")) {
builder.setDisableInviteFunctions(options.getBoolean("disableInviteFunctions"));
}

// Set the feature flags
if (options.hasKey("featureFlags")) {
ReadableMap featureFlags = options.getMap("featureFlags");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -134,6 +134,14 @@ public void setOptions(RNMeetHourView view, ReadableMap options) {
builder.setVideoMuted(options.getBoolean("videoMuted"));
}

if (options.hasKey("prejoinPageEnabled")) {
builder.setPrejoinPageEnabled(options.getBoolean("prejoinPageEnabled"));
}

if (options.hasKey("disableInviteFunctions")) {
builder.setDisableInviteFunctions(options.getBoolean("disableInviteFunctions"));
}

// Set the feature flags
if (options.hasKey("featureFlags")) {
ReadableMap featureFlags = options.getMap("featureFlags");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -103,6 +103,18 @@ public Builder setVideoMuted(boolean videoMuted) {
return this;
}

public Builder setPrejoinPageEnabled(boolean prejoinPageEnabled) {
setConfigOverride("prejoinPageEnabled", prejoinPageEnabled);

return this;
}

public Builder setDisableInviteFunctions(boolean disableInviteFunctions) {
setConfigOverride("disableInviteFunctions", disableInviteFunctions);

return this;
}

public Builder setFeatureFlag(String flag, boolean value) {
this.featureFlags.putBoolean(flag, value);

Expand Down
8 changes: 8 additions & 0 deletions ios/MeetHourUtil.swift
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,14 @@ struct MeetHourUtil {
builder.videoMuted = videoMuted
}

if let prejoinPageEnabled = options["prejoinPageEnabled"] as? Bool {
builder.prejoinPageEnabled = prejoinPageEnabled
}

if let disableInviteFunctions = options["disableInviteFunctions"] as? Bool {
builder.disableInviteFunctions = disableInviteFunctions
}

}
}
}
4 changes: 2 additions & 2 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "react-native-meet-hour-sdk",
"description": "Meet Hour SDK for React Native.",
"version": "3.0.19",
"version": "3.0.20",
"author": "MeetHour, LLC <[email protected]>",
"contributors": [],
"homepage": "https://github.com/v-empower/react-native-meet-hour-sdk",
Expand Down
2 changes: 1 addition & 1 deletion react-native-meet-hour-sdk.podspec
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ Pod::Spec.new do |s|
s.source_files = "ios/**/*.{h,m,mm,swift}"

s.dependency "React-Core"
s.dependency 'MeetHourSDK', '4.2.3'
s.dependency 'MeetHourSDK', '4.2.4'
s.pod_target_xcconfig = { 'DEFINES_MODULE' => 'YES', 'VALID_ARCHS[sdk=iphonesimulator*]' => 'x86_64' }
s.swift_version = '5.0'
end
2 changes: 2 additions & 0 deletions src/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,9 @@ export interface MeetHourConferenceOptions {
subject?: string;
audioOnly?: boolean;
audioMuted?: boolean;
prejoinPageEnabled?: boolean;
videoMuted?: boolean;
disableInviteFunctions?: boolean;
featureFlags?: { [key: string]: boolean };
}

Expand Down

0 comments on commit ba72605

Please sign in to comment.