voxeet/voxeet-uxkit-react

Screensharing button not working

Closed this issue · 2 comments

Describe the bug

Using the conference component, when I start a video call with another browser, clicking on the screenshare button does nothing

Expected Behaviour

Screensharing should start

Steps to Reproduce the Problem

  1. As per description

Minimalistic code (recommended)

const getSettings = () => {
    const { user } = props;

    let userInfo = {};

    if (user) {
      userInfo = {
        ...user,
      };
    }

    return {
      consumerKey: process.env.DOLBY_VOXEET_KEY,
      consumerSecret: process.env.DOLBY_VOXEET_SECRET,
      constraints: {
        audio: true,
        video: true,
      },
      videoRatio: {
        width: 1920,
        height: 1080,
      },
      videoCodec: 'H264',
      userInfo,
      sdk: voxeet.instance,
    };
  };

  return (
    <>
      <GlobalStyles />
      <ConferenceRoom
        loadingScreen={Loading}
        actionsButtons={ActionButtons}
        attendeesChat={() => null}
        isWidget={false}
        autoJoin
        kickOnHangUp
        handleOnLeave={handleOnLeave}
        handleOnConnect={handleOnConnect}
        {...getSettings()}
        conferenceAlias={callId}
      />
    </>
  );

Specifications

  • Device: Macbook pro
  • OS: Catalina
  • Platform: Chrome
  • Subsystem: na
  • Version:
    • @voxeet/voxeet-web-sdk 2.4.3
    • @voxeet/react-components 2.1.2
    • node 14

from doing a bit of debugging, it looks to me like the ActionButton onClick event should be passing 'screenshare' as the event, as toggleScreenShare looks to be checking for it?

i.e.

<ActionButton
   icon={isScreenshare ? ShareScreenOffIcon : ShareScreenIcon}
   onClick={toggleScreenShare}
   size={40}
/>

doesnt work, but the following does -

<ActionButton
   icon={isScreenshare ? ShareScreenOffIcon : ShareScreenIcon}
   onClick={() => toggleScreenShare('screenshare')}
   size={40}
/>

Apologies, the bug is not in this library, it's in https://github.com/GetStream/stream-dolby-voxeet/ looks like their demo code is either out of date or just wrong.

Closing