Commit Graph

510 Commits

Author SHA1 Message Date
Lyubo Marinov 8436f23e05 Comments 2017-08-31 19:31:46 -05:00
hristoterezov cd3dad956b fix(peopleSearch): queryTypes are defined in config.js 2017-08-31 15:04:29 -05:00
Saúl Ibarra Corretgé 328da08b3a [RN] Remove obsolete comment
We have already made the implicit decision not to pursue what the
comment describes. If we ever revisit it, it probably won't be handled
where the comment is anyway.
2017-08-31 11:50:18 -05:00
Leonard Kim 05f8c69fe6 ref(toolbar): add wrapper around buttons for torture tests
The torture tests were looking for the anchor tag within each
button. However, that anchor could get blown away from a react
re-render. So instead, expose a way for the torture tests
to find the root node of the button.
2017-08-30 11:31:15 -05:00
Leonard Kim 7063f144ef feat(tooltips): add for video quality label and feedback button 2017-08-30 11:10:28 -05:00
Leonard Kim 5e4f921e1b ref(video-quality-label): do not show quality dialog 2017-08-30 11:10:28 -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é e33030582f [RN] Show a progress indicator in the BlankPage
It will only be shown when there are ongoing network requests.
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é 8eebfcad72 [RN] Add support for callstats on mobile
The global.performance.now polyfill is removed since it's polyfilled by
react-native-callstats.
2017-08-29 18:47:35 -05:00
virtuacoplenny ef1b8fdb77 ref(1-on-1): move remote video visibility to a selector (#1922)
* ref(1-on-1): move remote visibility to a selector

Derive whether or not remote videos should display using a selector
to look across different states. A selector was chosen over using
memoized selectors (reselect) or subscribers as a first step
approach, avoiding additional mutations caused by a subscriber
updating the filmstrip state and avoiding additional api overhead
introduced by reselect.

* rename selector
2017-08-29 10:08:16 -05:00
Saúl Ibarra Corretgé c0f648b1ab [RN] Remove no longer needed fetch API fallback 2017-08-29 10:30:09 +01:00
Saúl Ibarra Corretgé 531b638a8a [RN] Switch default avatars to meeples 2017-08-29 09:27:28 +01:00
bbaldino f616b0b71b few tweaks to fix some exceptions in edge 2017-08-28 21:52:52 +00:00
hristoterezov 70422f4a47 fix(alwaysontop): change the size of the toolbar 2017-08-28 14:52:31 -05:00
virtuacoplenny 735a596afe ref(recording): convert recording label to react (#1915)
* ref(recording): convert recording label to react

- Create a RecordingLabel component for displaying the current
  recording state, as reflected in the redux store. This is
  needed for 1-on-1 mode to be completely in redux.
- Update the store with the recording state so RecordingLabel
  can update itself.
- Remove previous logic for updating the non-react label, which
  includes event emitting for filmstrip visibility changes,
  as RecordingLabel is hooked into redux updates.

* ref(recording): use status and type constants from lib

* make label really dumb, move logic back to Recording
2017-08-25 11:45:30 -05:00
Leonard Kim 85f0ad2791 feat(popover): create a wrapper around InlineDialog 2017-08-24 22:00:14 -05:00
Leonard Kim fdee6dc360 fix(inline-dialog): reimplement popover display on mouse move
Create empty elements within InlineDialog content that can be
used to bridge mouse movement from the InlineDialog trigger to
the InlineDialog content. The empty elements are positioned
absolute so they can break out of the InlineDialog container
and not affect popper's position calculations.
2017-08-24 22:00:14 -05:00
Lyubo Marinov 24db52ef0f [RN] Remove denied permission alert from WelcomePage 2017-08-22 16:38:14 -05:00
Lyubo Marinov 0b8c12de0e Simplify route navigation
I see it as the first step in simplifying the route navigate of the
JavaScript app by removing BlankWelcomePage from _getRouteToRender. From
a faraway point of view, the app is at the route at which it is not in a
conference. Historically, the route was known as the Welcome page. But
mobile complicated the route by saying that actually it may not want to
see the room name input and join button.

Additionally, I renamed BlankWelcomePage to BlankPage because I don't
think of it as a WelcomePage alternative but rather as a more generic
BlankPage which may be utilized elsewhere in the future.

I plan for the next steps to:
* Merge Entryway, _interceptComponent, and _getRouteToRender in one
React Component rendered by AbstractApp so that the whole logic is in
one file;
* Get rid of RouteRegistry and routes.
2017-08-22 16:38:14 -05:00
Lyubo Marinov cb5b93fb6e Switch to prop-types 2017-08-22 16:38:14 -05:00
Lyubo Marinov 7114614697 Remove obsolete workaround 2017-08-22 16:38:14 -05:00
Leonard Kim ec22329408 ref(local-video): generate html instead of hardcoding in filmstrip
This would better mimic React behavior where each component has
its own markup, instead of relying on markup existing elsewhere.
2017-08-22 10:27:34 -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
Saúl Ibarra Corretgé 9bca0e3b3d [RN] Create tracks right when they are required
When do we need tracks?

- Welcome page (only the video track)
- Conference (depends if starting with audio / video muted is requested)

When do we need to destroy the tracks?

- When we are not in a conference and there is no welcome page

In order to accommodate all the above use cases, a new component is introduced:
BlankWelcomePage. Its purpose is to take the place of the welcome page when it
is disabled. When this component is mounted local tracks are destroyed.

Analogously, a video track is created when the (real) welcome page is created,
and all the desired tracks are created then the Conference component is created.
What are desired tracks? These are the tracks we'd like to use for the
conference that is about to happen. By default both audio and video are desired.
It's possible, however, the user requested to start the call with no
video/audio, in which case it's muted in base/media and a track is not created.

The first time the app starts (with the welcome page) it will request permission
for video only, since there is no need for audio in the welcome page. Later,
when a conference is joined permission for audio will be requested when an audio
track is to be created. The audio track is not destroyed when the conference
ends. Yours truly thinks this is not needed since it's a stopped track which is
not using system resources.
2017-08-22 07:28:19 -05:00
Saúl Ibarra Corretgé 3102ea6818 [RN] Try to create local tracks when unmuting, if track is missing
This is only desired when the unmuting action took place due to a manual user
intervention or the audio-only mode being disengaged.
2017-08-22 07:28:19 -05:00
Leonard Kim 28b4595561 ref(tooltips): remove old tooltips 2017-08-21 15:16:09 -05:00
Leonard Kim e3361e2f3b feat(tooltips): convert popup tooltips to InlineDialog 2017-08-21 15:16:09 -05:00
Leonard Kim c3a4a38414 feat(toolbar): use AtlasKit tooltip 2017-08-21 15:16:09 -05:00
Leonard Kim 38e2443ab7 feat(small-video): use AtlasKit tooltip 2017-08-21 15:16:09 -05:00
Saúl Ibarra Corretgé c42f1704ff [RN] Rename createInitialLocalTracks to createLocalTracks
The name better suits its purpose, since it can be called at any time.
2017-08-21 08:15:55 -05:00
Leonard Kim 5358f022ff fix(config): override config values instead of merging
Iterate over objects and copy over primitives and arrays
instead of using _.merge, as merge will not replace a config
entry completely. For arrays in a target object, the arrays
will have its indices replaced. This means if a source array
is empty, the target array will be left alone. Similarly,
if the target array is longer than a source array, there
will be indices not touched in the target array.
2017-08-21 07:07:18 -05:00
hristoterezov 5ef914602f fix(remotecontrol): Handle screen sharing cancel 2017-08-21 10:41:24 +01:00
Lyubo Marinov 2818520c8f [RN] Make react-native-img-cache optional at bundle time 2017-08-18 14:54:25 -05:00
Lyubo Marinov 131e5af01e [RN] Fix a strange import of a feature by itself 2017-08-18 14:52:41 -05:00
Lyubo Marinov 90e7804834 Coding style 2017-08-18 14:47:15 -05:00
Lyubo Marinov c0de88ba8c [RN] Remove unnecessary import 2017-08-18 14:45:00 -05:00
Paweł Domas 99ce46cfa8 feat(conference, toolbox, API) get rid of {audio,video}Muted' flags
* ref: video muted state

Get rid of 'videoMuted' flag in conference.js

* ref: audio muted state

Get rid of 'audioMuted' flag in conference.js

* fix(conference.js|API): early audio/video muted updates

* ref(conference.js): rename isVideoMuted

Rename isVideoMuted to isLocalVideoMuted to be consistent with
isLocalAudioMuted.

* doc|style(conference.js): comments and space after if

* ref: move 'setTrackMuted' to functions

* fix(tracks/middleware): no-lonely-if

* ref(features/toolbox): get rid of last argument

* ref(defaultToolbarButtons): rename var
2017-08-18 13:30:30 +02:00
Leonard Kim 27deb97c5c ref(filmstrip): hook filmstrip to redux for 1-on-1 mode
- Remove non-redux paths for hiding and showing remote videos.
- Hook web filmstrip to redux to know when to hide remote videos.
  This works, even though VideoLayout is handling RemoteVideo
  appending, because react is only monitoring filmstrip's declared
  JSX which does not change except for attributes (css classes).
2017-08-17 17:27:30 -05:00
hristoterezov 378a8d014e feat(remotecontrol): Prevent multiple remote control sessions (#1875) 2017-08-17 09:43:22 -07:00
Lyubo Marinov c1fbbc4571 Reduce duplication 2017-08-16 16:28:39 -05:00
yanas 3d397a28e6 Updates default avatar image 2017-08-16 14:42:41 -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
virtuacoplenny 3e3577766d fix(quality-slider): prevent resizing by making p2p warning hidden (#1890)
* fix(quality-slider): prevent resizing by making p2p warning hidden

Instead of removing and appending the p2p warning, make it always
appended but toggle visibility so it always takes up space. This
should prevent resizing when the warning appears. Margin and
padding were adjusted to account for the empty space displayed
by a hidden p2p warning.

* let vertical size change
2017-08-15 15:22:32 -05:00
virtuacoplenny 1b7973a28e ref(invite): use AtlasKit for invite modal buttons and inputs (#1868)
* ref(invite): use AtlasKit for invite modal buttons and inputs

- Convert button to AK Button.
- Convert inputs to AK FieldText.

* remove noop, replace with custom empty func
2017-08-15 14:30:57 -05:00
Leonard Kim 830ec3d097 fix(video-quality): change click handler location on label
This will prevent the quality dialog from closing when changing
desired quality level.
2017-08-14 15:13:29 -05:00
virtuacoplenny 725d39ddcd feat(jitsipopover): convert to InlineDialog (#1804)
* feat(small-video): use InlineDialog for stats and remote menu

- Remove JitsiPopover and use InlineDialog instead.
- Bring the remote menu icon into react.
- Make vertical filmstrip position:fixed so popper (AtlasKit
  dependency) sets InlineDialogs and eventually tooltips to
  position:fixed.

* ref(remote-menu): hook KickButton to redux

* ref(remote-menu): hook MuteButton to redux

* modify padding, toggle dialogs

* pixel push margins to align dialogs, adjust padding of dialogs

* add comment about margin for dialog, add file I forgot

* modify indicator markup so the icon can be moved down while trigger stays at top of toolbar
2017-08-14 10:02:58 -05:00
Saúl Ibarra Corretgé 2e3a5b1c35 [RN] Fix jsdocs 2017-08-14 12:23:46 +02:00
hristoterezov 1782030936 feat(alwaysontop): Toolbar. 2017-08-11 17:07:24 -07:00