@@ -61,7 +61,7 @@ function Controlbar() {
};
const leaveMeeting = () => {
- meeting.leaveRoom();
+ meeting.leave();
};
return (
diff --git a/samples/live-auction/src/pages/meeting/Meeting.tsx b/samples/live-auction/src/pages/meeting/Meeting.tsx
index 505479b..0c7dad8 100644
--- a/samples/live-auction/src/pages/meeting/Meeting.tsx
+++ b/samples/live-auction/src/pages/meeting/Meeting.tsx
@@ -92,12 +92,12 @@ const Meeting = () => {
}
}
- document.body.addEventListener('dyteStateUpdate', handleDyteStateUpdate);
+ document.body.addEventListener('rtkStateUpdate', handleDyteStateUpdate);
return () => {
- document.body.removeEventListener('dyteStateUpdate', handleDyteStateUpdate);
+ document.body.removeEventListener('rtkStateUpdate', handleDyteStateUpdate);
meeting.participants.removeListener('broadcastedMessage', handleBroadcastedMessage);
- }
+ };
}, [meeting])
useEffect(() => {
diff --git a/samples/live-auction/src/pages/setupScreen/SetupScreen.tsx b/samples/live-auction/src/pages/setupScreen/SetupScreen.tsx
index 2e953e7..5b06c9f 100644
--- a/samples/live-auction/src/pages/setupScreen/SetupScreen.tsx
+++ b/samples/live-auction/src/pages/setupScreen/SetupScreen.tsx
@@ -28,7 +28,7 @@ const SetupScreen = () => {
const joinMeeting = () => {
meeting?.self.setName(name);
- meeting.joinRoom();
+ meeting.join();
}
return (
diff --git a/samples/screenshare-focused-ui-with-custom-addons/src/components/custom-dyte-grid.tsx b/samples/screenshare-focused-ui-with-custom-addons/src/components/custom-dyte-grid.tsx
index 3ff85c8..3244f25 100644
--- a/samples/screenshare-focused-ui-with-custom-addons/src/components/custom-dyte-grid.tsx
+++ b/samples/screenshare-focused-ui-with-custom-addons/src/components/custom-dyte-grid.tsx
@@ -27,7 +27,7 @@ function CustomDyteGridScreenshareFocused({
const [reactions, setReactions] = useState<{[key: string]: string}>({});
const activeParticipants = useRealtimeKitSelector((meeting) =>
- meeting.participants.active.toArray()
+ meeting.participants.videoSubscribed.toArray()
);
const pinnedParticipants = useRealtimeKitSelector((meeting) =>
diff --git a/samples/screenshare-focused-ui-with-custom-addons/src/components/in-meeting.tsx b/samples/screenshare-focused-ui-with-custom-addons/src/components/in-meeting.tsx
index 5c32203..0766a94 100644
--- a/samples/screenshare-focused-ui-with-custom-addons/src/components/in-meeting.tsx
+++ b/samples/screenshare-focused-ui-with-custom-addons/src/components/in-meeting.tsx
@@ -23,7 +23,7 @@ function InMeeting({
{
- el?.addEventListener('dyteStateUpdate', (e) => {
+ el?.addEventListener('rtkStateUpdate', (e) => {
const { detail: newStateUpdate } = e as unknown as { detail: CustomStates };
console.log('dyteStateUpdateSetup:: ', newStateUpdate);
setStates((oldState: CustomStates) => { return {
diff --git a/samples/screenshare-focused-ui-with-custom-addons/src/components/setup-screen.tsx b/samples/screenshare-focused-ui-with-custom-addons/src/components/setup-screen.tsx
index 67968e5..e6f23db 100644
--- a/samples/screenshare-focused-ui-with-custom-addons/src/components/setup-screen.tsx
+++ b/samples/screenshare-focused-ui-with-custom-addons/src/components/setup-screen.tsx
@@ -17,7 +17,7 @@ export function SetupScreenPreBuilt({
backgroundColor: '#272727',
color: '#ffffff',
}} ref={(el) => {
- el?.addEventListener('dyteStateUpdate', (e) => {
+ el?.addEventListener('rtkStateUpdate', (e) => {
const { detail: newStateUpdate } = e as unknown as { detail: CustomStates };
console.log('dyteStateUpdateSetup:: ', newStateUpdate);
setStates((oldState: CustomStates) => { return {
@@ -49,7 +49,7 @@ export function CustomSetupScreenWithPrebuiltMediaPreviewModal({
return (
{
- el?.addEventListener('dyteStateUpdate', (e) => {
+ el?.addEventListener('rtkStateUpdate', (e) => {
const { detail: newStateUpdate } = e as unknown as { detail: CustomStates };
console.log('dyteStateUpdateSetup:: ', newStateUpdate);
setStates((oldState: CustomStates) => { return {
diff --git a/samples/simple-group-call/src/components/Meeting.tsx b/samples/simple-group-call/src/components/Meeting.tsx
index e5dda4d..b146362 100644
--- a/samples/simple-group-call/src/components/Meeting.tsx
+++ b/samples/simple-group-call/src/components/Meeting.tsx
@@ -24,7 +24,7 @@ function UI() {
const { meeting } = useRealtimeKitMeeting();
const self = useRealtimeKitSelector((meeting) => meeting.self);
const activeParticipants = useRealtimeKitSelector((meeting) =>
- meeting.participants.active.toArray()
+ meeting.participants.videoSubscribed.toArray()
);
const pinnedParticipants = useRealtimeKitSelector((meeting) =>
diff --git a/samples/simple-ui/src/App.tsx b/samples/simple-ui/src/App.tsx
index 128366e..04e8f8d 100644
--- a/samples/simple-ui/src/App.tsx
+++ b/samples/simple-ui/src/App.tsx
@@ -53,7 +53,7 @@ function Meeting() {
{
- el?.addEventListener('dyteStateUpdate', (e: any) => {
+ el?.addEventListener('rtkStateUpdate', (e: any) => {
updateStates(e.detail);
});
}}
@@ -102,7 +102,7 @@ function App() {
audio: false,
video: false,
},
- }).then((m) => m?.joinRoom());
+ }).then((m) => m?.join());
}, []);
// By default this component will cover the entire viewport.