Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use a local widget wrapper for Jitsi calls #12780

Merged
merged 2 commits into from
Mar 19, 2020
Merged

Conversation

turt2live
Copy link
Member

@turt2live turt2live commented Mar 18, 2020

Effectively fixes #11074
Effectively fixes #7112
Fixes #6930
Fixes Jitsi widgets not working for guests (#8933)
Fixes #5048

Requires matrix-org/matrix-react-sdk#4234

Previously we were relying on an integration manager to be defined, functional, and alive in order to join Jitsi calls. This commit changes this so we aren't reliant on an integration manager for Jitsi calls at all, and gives people the option of choosing a Jitsi server via the config.json.

This side is just the wrapper/shell: the logic is mostly in the react-sdk (to be linked via PRs). This layer simply has an HTML file exported that can be used to render a Jitsi widget, and the react-sdk constructs a URL to access it locally. This is similar to how the mobile apps handle Jitsi widgets: instead of iframing the widget URL directly into the app, they pull apart the widget information and natively render it. We're effectively doing the same here by parsing the widget options and using our local wrapper instead of whatever happens to be defined in the widget state event.

Integration managers should still continue to offer a widget URL for Jitsi widgets as this is what the spec requires.

A large part of this is based upon Dimension's handling of Jitsi and widgets in general: a license has been granted to allow Riot (and therefore the react-sdk) to use the code and be inspired by it.

Effectively fixes #11074
Effectively fixes #7112
Fixes #6930
Fixes Jitsi widgets not working for guests (#8933)
Fixes #5048

Previously we were relying on an integration manager to be defined, functional, and alive in order to join Jitsi calls. This commit changes this so we aren't reliant on an integration manager for Jitsi calls at all, and gives people the option of choosing a Jitsi server via the config.json.

This side is just the wrapper/shell: the logic is mostly in the react-sdk (to be linked via PRs). This layer simply has an HTML file exported that can be used to render a Jitsi widget, and the react-sdk constructs a URL to access it locally. This is similar to how the mobile apps handle Jitsi widgets: instead of iframing the widget URL directly into the app, they pull apart the widget information and natively render it. We're effectively doing the same here by parsing the widget options and using our local wrapper instead of whatever happens to be defined in the widget state event.

Integration managers should still continue to offer a widget URL for Jitsi widgets as this is what the spec requires.

A large part of this is based upon Dimension's handling of Jitsi and widgets in general: a license has been granted to allow Riot (and therefore the react-sdk) to use the code and be inspired by it.
turt2live added a commit to matrix-org/matrix-react-sdk that referenced this pull request Mar 18, 2020
@turt2live
Copy link
Member Author

Types Lint passes locally - looks like it doesn't pull cross-repo branches.

F:\Workspaces\riot-web\riot-web>yarn lint:types
yarn run v1.22.0
$ tsc --noEmit --jsx react
Done in 2.93s.

@turt2live turt2live marked this pull request as ready for review March 18, 2020 21:59
@turt2live turt2live requested a review from a team March 18, 2020 21:59
@jryans jryans requested review from jryans and removed request for a team March 19, 2020 15:30
Copy link
Collaborator

@jryans jryans left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good overall! 😁

src/vector/jitsi/index.html Outdated Show resolved Hide resolved
src/vector/jitsi/index.scss Outdated Show resolved Hide resolved
src/vector/jitsi/index.scss Outdated Show resolved Hide resolved
src/vector/jitsi/index.ts Outdated Show resolved Hide resolved
@turt2live turt2live merged commit 775e1fc into develop Mar 19, 2020
@turt2live turt2live deleted the travis/wrapped-jitsi branch March 19, 2020 17:52
@rzr
Copy link

rzr commented Apr 3, 2020

Nice feature, may I suggest that the widget title to be more explicit "jitsi" is not self describing enough, I would expect a title like "Video and Audio conference using jitsi widget (click here to show)"

t3chguy pushed a commit that referenced this pull request Oct 17, 2024
…or matrixrtc (#12780)

* update restricted import rules for matrixrtc

* review

* upgrade matrix-js-sdk

* add missing import
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
3 participants