Commit Graph

146 Commits

Author SHA1 Message Date
zbettenbuk 959db3a665 Make web use the redux settings/profile 2018-05-09 15:20:22 +02:00
Ryan Peck f64c13d4b7 [RN] add support for inviting participants during a call on mobile
* Button conditionally shown based on if the feature is enabled and available
* Hooks for launching the invite UI (delegates to the native layer)
* Hooks for using the search and dial out checks from the native layer (calls back into JS)
* Hooks for handling sending invites and passing any failures back to the native layer
* Android and iOS handling for those hooks

Author: Ryan Peck <rpeck@atlassian.com>
Author: Eric Brynsvold <ebrynsvold@atlassian.com>
2018-04-25 18:58:06 +02:00
paweldomas 26cd2f17f6 ref(chat): port incoming chat msg sound to react 2018-03-13 16:57:28 -05:00
paweldomas 60e03e3dec feat: add join/leave sounds on mobile
Adds base/sounds feature which allows other features to register a sound
source under specified id. A new SoundsCollection component will then
render corresponding HTMLAudioElement for each such sound. Once "setRef"
callback is called by the HTMLAudioElement, this element will be added
to the Redux store. When that happens sound can be played through the
new 'playSound' action which will call play() method on the stored
HTMLAudioElement instance.
2018-03-13 16:57:28 -05:00
Lyubo Marinov d727ee80b2 [RN] Fix base/profile and recent-list bugs 2018-02-27 20:52:34 -06:00
Lyubo Marinov b8de5bbfc3 [RN] Add Picture-in-Picture support (Coding style: naming, consistency) 2018-02-23 11:21:26 -06:00
Saúl Ibarra Corretgé b3683068d4 [RN] Add Picture-in-Picture support
This only works automatically on Android >= 8. On other platforms / versions, it
relies on the SDK user on implementing a "reduced UI" mode and reacting to the
"request PIP" delegate method.
2018-02-23 11:21:25 -06:00
Saúl Ibarra Corretgé 5305557ce5 [RN] Add a "reduced UI" mode
It's detected based on a size threshold.
2018-02-06 15:53:52 -06:00
Lyubo Marinov c9d8b5c827 Finally! Let there be... responsive-ui!
We started on the way to responsive UI and its design with aspect ratio
and keeping the filmstrip on the short side of the app's visible
rectangle.

Shortly, we're going to introduce reduced UI for Picture-in-Picture. And
that's where we'll need another dimensions-based detector akin to the
aspect ratio detector.

While the AspectRatioDetector, the up-and-coming ReducedUIDetector, and
their base DimensionsDetector are definitely separate abstractions and
implementations not mixed for the purposes of easy extensibility and
maintenance, the three of them are our building blocks on top of which
we'll build our responsive UI.
2018-02-06 15:53:27 -06:00
Lyubo Marinov 62c9762793 [RN] Protect AbstractApp and localStorage initialization 2018-02-05 15:26:01 -06:00
Lyubo Marinov d7dddb2509 Introduce base/storage to represent the Web Storage API and persistence-related customizations 2018-02-02 15:13:26 -06:00
Lyubo Marinov 7954d5fd39 Coding style 2018-02-02 15:13:26 -06:00
zbettenbuk 158cadf4f9 Improve persistency layer 2018-02-02 15:13:26 -06:00
Saúl Ibarra Corretgé 98ff20a026 [RN] Simplify initialization of AsyncStorage 2018-01-19 09:41:34 -06:00
Lyubo Marinov 112c856850 Fix settings screen layout on iOS and add soft back button 2018-01-18 15:45:25 -06:00
zbettenbuk 410dc132e1 Fix settings screen layout on iOS and add soft back button 2018-01-18 10:06:26 -06:00
zbettenbuk 05a492241f Fix local participant details on web 2018-01-05 12:58:58 -06:00
zbettenbuk bfcd34358b [RN] Add app-settings feature
[RN] Fix PR feedbacks, write persistency docs
2018-01-04 12:53:29 -06:00
Lyubo Marinov b39b6640b4 React & React Native Fragment-like 2017-12-12 20:52:29 -06:00
Saúl Ibarra Corretgé 870e6bbddc feat(overlays): render overlays outside of Conference
On web Conference is pretty much all there is, but on mobile we have the welcome
page and the blank page. If we fail to load config.js, for example we will still
be in the welcome page *and* we want to show an error overlay.
2017-12-12 20:52:29 -06:00
Lyubo Marinov 8fd91573fc Fix eslint & flow errors
Prepares for the latest eslint & flow-related npm packages which cause
these errors.
2017-11-16 12:27:54 -06:00
Lyubo Marinov d0c079dba5 Coding style 2017-11-07 17:27:58 -06:00
paweldomas c0a7d6144a feat: display filmstrip on the short side
Adds the ability to detect app area's aspect ratio on react-native
through the features/base/aspect-ratio.

Makes conference, filmstrip and toolbox react to the aspect ratio
changes and display filmstrip on the shorter side of the screen.
2017-11-07 08:28:18 -06:00
Saúl Ibarra Corretgé 23550d377e feat(dark-theme): fix breakage on mobile
e09949be9f introduced the dark theme globally, but
it only applies to web, so move the logic to App.web.js
2017-10-23 09:12:31 -05:00
yanas e09949be9f feat(dark-theme): Applies dark theme on inline-dialogs, tooltips, flags and more 2017-10-20 15:29:16 -05:00
Saúl Ibarra Corretgé 8d11b3024e [iOS] Add initial CallKit support
This commit adds initial support for CallKit on supported platforms: iOS >= 10.

Since the call flow in Jitsi Meet is basically making outgoing calls, only
outgoing call support is currently handled via CallKit.

Features:
 - "Green bar" when in a call.
 - Native CallKit view when tapping on the call label on the lock screen.
 - Support for audio muting from the native CallKit view.
 - Support for recent calls (audio-only calls logged as Audio calls, others show
   as Video calls).
 - Call display name is room name.
 - Graceful downgrade on systems without CallKit support.

Limitations:
 - Native CallKit view cannot be shown for audio-only calls (this is a CallKit
   limitaion).
 - The video button in the CallKit view will start a new video call to the same
   room, and terminate the previous one.
 - No support for call hold.
2017-09-28 16:36:39 -05:00
Lyubo Marinov 2e2129fa44 Import PropTypes from prop-types
Prepare for React 16.
2017-09-27 16:24:53 -05:00
Saúl Ibarra Corretgé 35da39becf [RN] NetworkActivityIndicator
The basic indicator is extracted into a LoadingIndicator component,
which then NetworkActivityIndicator displays (or not) based on network
activity.
2017-09-20 15:59:56 -05:00
Lyubo Marinov 241dc3b147 [RN] Support XMPP authentication 2017-09-19 23:04:45 -05:00
paweldomas 141acea194 [RN] Support XMPP authentication 2017-09-19 14:38:45 -05:00
Lyubo Marinov 45a1ae26ca [RN] Prepare to display BlankPage more
For example, while config.js and other files are being loaded before the
navigation to Conference is feasible.
2017-09-02 13:26:06 -05:00
Lyubo Marinov 6545a7a1bb Remove duplication 2017-09-01 23:55:25 -05:00
Дамян Минков 6682543691 Moves analytics loading to react. (#1945)
* feat(analytics): move to React

The analytics handlers have been moved to JitsiMeetGlobalNS, so now they are
stored in `window.JitsiMeetJS.app.analyticsHandlers`.

The analytics handlers are re-downloaded and re-initialized on every
lib-jitsi-meet initialization, which happens every time the config is changed
(moving between deployments in the mobile app).

* Adds legacy support for old analytics location.
2017-09-01 14:14:03 -05:00
Lyubo Marinov 7f8e8177d0 [RN] Refactor "Keep track of ongoing network requests" and "Show a progress indicator in the BlankPage"
I'm not saying that the two commits in question were wrong or worse than
what I'm offering. Anyway, I think what I'm offering brings:

* Compliance with expectations i.e. the middleware doesn't compute the
next state from the current state, the reducer does;

* Clarity and/or simplicity i.e. there's no global variable (reqIndex),
there's no need for the term "index" (a.k.a "reqIndex") in the redux
store.

* By renaming net-interceptor to network-activity feels like it's
preparing the feature to implement a NetworkActivityIndicator React
Component which will take on more of the knowledge about the specifics
of what is the network activity redux state exactly, is it maintained by
interception or some other mechanism, and abstracts it in the feature
itself allowing outsiders to merely render a React Component.
2017-08-29 18:54:04 -05:00
Saúl Ibarra Corretgé d669a6c73c [RN] Keep track of ongoing network requests
Works only for XHR requests, which is the only network request mobile performs
(WebRTC traffic aside). The fetch API is implemented on top of XHR, so that's
covered too.

Requests are kept in the redux store until they complete, at which point they
are removed.
2017-08-29 18:54:04 -05:00
Saúl Ibarra Corretgé 26f0f7f89c [RN] Alert the user when they need to manually grant a permission 2017-08-22 07:28:19 -05:00
Lyubo Marinov c0de88ba8c [RN] Remove unnecessary import 2017-08-18 14:45:00 -05:00
Lyubo Marinov 6003b560ae [RN] Fix opening the same URL multiple times
Deep/universal linking now utilizes loadURL (when possible). But loadURL
is imperative in the native source code while its JavaScript counterpart
i.e. React App Component prop url is declarative. So there's the
following bug: open a URL, leave the conference (by tapping the hangup
button, for example), and then opening the same URL actually leaves you
on the Welcome page (if enabled; otherwise, a black screen).

The implementation has a flow though: opening the same URL twice in a
row without an intervening leave will leave the first opening and join
the new opening. Which can be improved by not leaving and joining if the
conference is joined, joining, an not leaving. But that can be done
separately as an improvement independent of the current implementation
details.
2017-08-15 17:32:37 -05:00
Lyubo Marinov 571958cf26 Start the switch to prop-types
As https://facebook.github.io/react/docs/typechecking-with-proptypes.html
says, React.PropTypes have moved into the npm package prop-types since
React v15.5. I've already failed to update certain devDependencies
because they mandate the use of prop-types so I'd rather we (gradually
at least) move to prop-types rather than face a lot of work later on.
2017-08-15 17:32:37 -05:00
Saúl Ibarra Corretgé 122ebe48c7 [RN] Cache avatars and provide a default in case load fails
Avatars are cached to the filesystem and loaded from there when requested again.
The cache is cleaned after a conference ends and on application startup
(defensive move).

In addition, implement a fully local avatar system, which is used as a fallback
when loading a remote avatar fails. It can also be forced using a prop.

The fully local avatars use a user icon as a mask and apply a background color
qhich is picked by hashing the URI passed to the avatar. If no URI is passed a
random color is chosen.

A grace period of 1 second is also implemented so a default local avatar will be
rendered if an Avatar component is mounted but has no URI. If a URI is specified
later on, it will be loaded and displayed. In case loading the remote avatar
fails, the locally generated one will be used.
2017-08-03 13:45:41 -05:00
Lyubo Marinov caea02a322 [RN] Mitigate 'Not joining a new URL while in a conference' 2017-08-01 06:31:03 -05:00
Lyubo Marinov 3546cf4915 Fixes jsdocs, formatting 2017-07-26 15:54:57 -05:00
Lyubo Marinov a2c2d3bee1 [RN] Alternative to JitsiMeetView.loadURL w/o URL
Introduces loadURLObject in JitsiMeetView on Android and iOS which
accepts a Bundle and NSDictionary, respectively, similar in structure to
the JS object accepted by the constructor of Web's ExternalAPI. At this
time, only the property url of the bundle/dictionary is supported.
However, it allows the public API of loadURLObject to be consumed. The
property url will be made optional in the future and other properties
will be supported from which a URL will be constructed.
2017-07-26 15:53:35 -05:00
Lyubo Marinov 96e0c56bde [RN] Don't override config values 2017-07-21 17:40:09 -05:00
Lyubo Marinov 7dbba59dee [RN] Disconnect/hangup before joining a new URL 2017-07-06 15:00:29 -05:00
Lyubo Marinov 61fd4e4ce4 [RN] Fix passing url prop to Root and App components 2017-07-06 14:59:57 -05:00
Lyubo Marinov 9bd6bbfd95 Fix jsdocs. Simplify the source code 2017-07-06 14:59:57 -05:00
Saúl Ibarra Corretgé cc9249ba1a [RN] Fix passing url prop to Root and App components
React (pun intended) to prop changes, that is, load the new specified URL.

In addition, fix a hidden bug in loading the initial URL from the linking
module: we prefer a prop to the URL the app was launched with, in case somehow
both are specified. We (the Jitsi Meet app) are not going to run into this
corner case, but let's be defensive just in case.
2017-07-06 14:59:57 -05:00
Lyubo Marinov 5f64ccb97d [RN] Naming 2017-06-09 14:51:31 -05:00
Saúl Ibarra Corretgé 4687c1f465 [RN] Add ability to skip the welcome page
Also expose this in the native SDKs.
2017-06-09 14:10:10 -05:00
Saúl Ibarra Corretgé 79d51bc379 feat(App): remove obsolete config prop
It's obsolete now, since config is handled in Redux. Also add a "defaultUrl"
prop so emdedding applications can select what the default base URL is.
2017-06-09 14:10:10 -05:00
Saúl Ibarra Corretgé a075f24000 [RN] Add conference events to native SDKs
The current implementation doesn't use the API and Transport modules. This is
due to the fact that they are too tied to APP at the moment, which is web only.

Once API is refactored and moved into the Redux store this will be adjusted,
though it's unlikely that the lowest level React Native module (ExternalAPI)
changes drastically.

This commit also introduces a stopgap limitation of only allowing a single
instance for JitsiMeetView objects on both Android and iOS. React Native doesn't
really play well with having multiple instances of the same modules on the same
bridge, since they behave a bit like singletons. Even if we were to use multiple
bridges, some features depend on system-level global state, such as the
AVAudioSession mode or Android's immersive mode. Further attempts will be made
at lifting this limitation in the future, though.
2017-06-09 00:03:23 -05:00
Lyubo Marinov 4dc658c270 Fix 'Missing JSDoc comment  require-jsdoc' 2017-06-01 21:01:50 -05:00
Lyubo Marinov 320e67baa1 Fix the initialization of the (external) API
The counterpart of the external API in the Jitsi Meet Web app uses the
search URL param jwt to heuristically detect that the Web app is very
likely embedded (as an iframe) and, consequently, needs to forcefully
enable itself. It was looking at whether there was a JSON Web Token
(JWT) but that logic got broken when the JWT support was rewritten
because the check started happening before the search URL param jwt was
parsed.
2017-05-30 09:38:18 -05:00
Lyubo Marinov 2f3706bd37 [RN] Simplify
There were getDomain, setDomain, SET_DOMAIN, setRoomURL, SET_ROOM_URL
which together were repeating one and the same information and in the
case of the 'room URL' abstraction was not 100% accurate because it
would exist even when there was no room. Replace them all with a
'location URL' abstraction which exists with or without a room.

Then the 'room URL' abstraction was not used in (mobile) feature
share-room. Use the 'location URL' there now.

Finally, removes source code duplication in supporting the Web
application context root.
2017-05-09 16:31:21 -05:00
hristoterezov d91340166d Remote control - display the authorization dialog in meet (#1541)
* fix(react/participant): store display name in redux

* feat(remotecontrol): Add option to display the authorization dialog in meet

* feat(remotecontrol): Enable ESLint and Flow
2017-05-03 18:57:52 -05:00
Saúl Ibarra Corretgé 13e3375e8a [RN] Use proximity sensor when in audio-only mode
When the audio-only mode is enabled, turn on the proximity sensor to dim the
screen and disable touch controls when there is an object nearby.
2017-04-05 22:06:30 -05:00
yanas 3daae94bca Merge pull request #1379 from jitsi/base-react-dialogs-2
Password required dialog (web&native) and native room lock using basic react dialogs.
2017-04-03 10:52:33 -05:00
damencho 61470c0d24 Moves web password required dialog to react. 2017-03-30 14:21:05 -05:00
Lyubo Marinov 4e276471e5 Comply w/ coding style: consistency 2017-03-28 11:43:33 -05:00
Saúl Ibarra Corretgé c5eac63da1 [RN] Move all mobile only features to a subdirectory 2017-03-28 09:36:00 -05:00
Lyubo Marinov 23ddce122b Comply w/ coding style 2017-03-07 21:54:37 -06:00
hristoterezov 814bd26c07 feat(Avatar): Implement Avatar for web 2017-03-07 21:54:37 -06:00
Lyubo Marinov aef6e33c91 [RN] Fix remote JS debugging 2017-03-01 21:33:49 -06:00
Lyubo Marinov 18368fefaa Comply w/ coding style 2017-02-28 23:22:02 -06:00
damencho e3d4152e32 Adds react-i18next and its provider to react.
Adds translate function with default namespaces and options.
2017-02-28 13:13:47 -06:00
Saúl Ibarra Corretgé 5b6985fc5c [RN] Fix use of undefined APP
On RN we don't use the global APP object, so don't save the store there unless
it's defined, which is the case in the current web version. Also, check for
undefined explicitly, since a "if (!APP)" check will throw a ReferenceError.
2017-02-20 11:16:01 +01:00
hristoterezov 92d0589a37 ref(overlay): The overlays to use React 2017-02-18 17:03:50 -06:00
Lyubomir Marinov d93bd3eda7 [RN] Use a default host when only a room name is specified
The mobile app remembers the domain which hosted the last conference. If
the user specified a full URL first and specified a room name only the
second time, it was not obvious that the second conference would be
hosted on the domain of the first conference.
2017-02-18 10:04:08 -06:00
Lyubomir Marinov e29db31d91 Comply w/ coding style 2017-02-10 10:13:39 -06:00
Saúl Ibarra Corretgé 4519f26adf [RN] Mute local video when app is in the background 2017-02-10 00:44:37 -06:00
Lyubomir Marinov 8509efc8af Make the Web app aware of its context root 2017-02-07 08:27:23 -06:00
Saúl Ibarra Corretgé 7a8c84e990 [RN] Implement full screen mode while in a conference
The implementation varies across platforms, with the same goal: allow the app to
use the entire screen real state while in a conference.

On Android we use immersive mode, which  will hide the status and navigation bars.

https://developer.android.com/training/system-ui/immersive.html

On iOS the status bar is hidden, with a slide effect.
2017-02-06 13:51:17 -06:00
Lyubomir Marinov 366b2f1374 Simplify: Remove react/features/base/navigator 2017-01-28 19:56:35 -06:00
Lyubomir Marinov 49b3b49f3e Remove duplication
The files react/index.native.js and react/index.web.js ended up having
very similar source code related to initializing the Redux store. Remove
the duplication.

Additionally, I always wanted the App React Component to be consumed
without the need to provide a Redux store to it.
2017-01-26 17:24:11 -06:00
Lyubomir Marinov cbcee201f0 Comply w/ coding style 2017-01-26 07:58:46 -06:00
Ilya Daynatovich 2e81b8493e Introduce unsupported browser page 2017-01-26 07:27:31 -06:00
Lyubomir Marinov 62bafcaf63 Introduce Platform in React
React Native provides a Platform abstraction which React does not
provide.
2017-01-26 07:27:31 -06:00
Ilya Daynatovich 8248b14555 Integrate Mobile landing in the Redux app 2017-01-26 07:27:31 -06:00
Saúl Ibarra Corretgé 6c12681b9c [RN][iOS] Default to speaker for video conferences 2017-01-20 14:06:15 -06:00
Saúl Ibarra Corretgé acbfe5cb09 [RN] Keep device screen on while in a conference 2017-01-16 19:12:43 -06:00
Lyubomir Marinov ba3d65c01f Fix d17cc9fa
A bug was discovered in d17cc9fa which would raise a failure to push
into the browser's history if a base href was defined. Fix the failure
by removing react-router. Anyway, the usage of react-router was
incorrect because the app must hit the server infrastructure when it
enters a room because the server will choose the very app version then.
2017-01-15 18:28:02 -06:00
Lyubomir Marinov 856732abab Preserve URLs 2017-01-15 17:46:34 -06:00
Lyubomir Marinov 5f21e4c5b6 Introduce Platform in React
React Native provides Platform.
2017-01-15 12:09:52 -06:00
Lyubomir Marinov 0912dbf130 Remove duplication, simplify, comply with coding style 2017-01-12 10:37:01 -06:00
Lyubomir Marinov 2f01746c55 Remove duplication, simplify, comply with coding style 2017-01-10 13:06:18 -06:00
Lyubomir Marinov b67994235e Merge branch 'BeatC-moving-conference-init-to-react-1' of https://github.com/BeatC/jitsi-meet into BeatC-BeatC-moving-conference-init-to-react-1 2017-01-09 07:44:02 -06:00
Lyubomir Marinov 4fef8a3b79 [RN] Prevent unhandled JS errors from killing the process in Release 2017-01-05 15:06:41 -06:00
Ilya Daynatovich f53fb3d814 Introduced new actions and functions for app initialization 2017-01-04 17:46:47 +02:00
Ilya Daynatovich e716c1738c Fix lint errs 2017-01-04 17:46:47 +02:00
Ilya Daynatovich 3190bfa058 Move redundant code from app.js 2017-01-04 17:45:52 +02:00
Ilya Daynatovich c570b80d7b moved app initialization to react app 2017-01-04 17:45:52 +02:00
Lyubomir Marinov 0db33bb45c React propTypes as static class properties 2016-11-30 19:53:40 -06:00
Ilya Daynatovich c3428e8213 Split React components out of index.html 2016-11-24 02:21:02 -06:00
Lyubomir Marinov 7f3ff13c18 Merge jitsi-meet-react's mobile support
As a step toward merging jitsi-meet-react with jitsi-meet to share as
much source code as possible between mobile and Web, merge the part of
jitsi-meet-react's source tree which supports mobile inside the
jitsi-meet source tree and leave jitsi-meet-react's Web support in the
source code revision history but don't have it in master anymore because
it's different from jitsi-meet's Web support. In other words, the two
projects are mechanically merged at the file level and don't really
share source code between mobile and Web.
2016-10-12 10:31:52 -05:00
Lyubomir Marinov d55e0f70d9 Import jitsi/jitsi-meet-react#2f23d98
As an intermediate step on the path to merging jitsi-meet and
jitsi-meet-react, import the whole source code of jitsi-meet-react as it
stands at
2f23d98424
i.e. the lastest master at the time of this import. No modifications are
applied to the imported source code in order to preserve a complete
snapshot of it in the repository of jitsi-meet and, thus, facilitate
comparison later on. Consequently, the source code of jitsi-meet and/or
jitsi-meet-react may not work. For example, jitsi-meet's jshint may be
unable to parse jitsi-meet-react's source code.
2016-10-12 10:31:52 -05:00