Commit graph

258 commits

Author SHA1 Message Date
Rafael
b096aad70e Improve livestream claimLink embeds
- Remove embedPlayButton for fileRenderInitiator
- getThumbnailFromClaim from utils function instead of redux
- Improve playingUri
2022-03-16 16:36:50 -04:00
Rafael
6dea79819d livestream + old APIs 2022-03-16 16:36:50 -04:00
David Granado
7263bde491 Revert "Adjust logic to only run interval when video is playing."
This reverts commit 5ce6ab9689c1610f24869c7347b823cc2023b767.
2022-03-02 20:20:27 -08:00
David Granado
3631bdddbc Adjust logic to only run interval when video is playing. 2022-03-02 20:20:27 -08:00
David Granado
abb92726ab Rename variable to include value units 2022-03-02 20:20:27 -08:00
David Granado
4d438ed62f Widen save interval 2022-03-02 20:20:27 -08:00
David Granado
38f00be231 When video is playing, save position intermittently 2022-03-02 20:20:27 -08:00
mayeaux
0c4f85fe53
MAKE ODYSEE EVEN MORE BEAUTIFUL (#539)
WE LOVE YOU RAPHAEL FOR MAKING THIS HAPPEN!
2022-02-11 13:50:55 -05:00
Rafael
0c47f1daa9 Refactor fileRenderIninitiator component
- Only pass necessary props
- Created new initialize play redux action
- Removed deprecated ~file app download~ keyboard functionality, moved preventDefault to videojs keyboard events to prevent ~space~ moving down the page
2022-02-08 12:35:40 -05:00
AsadUmar
d73504d69c
fix render of toggle. (#819)
Co-authored-by: Thomas Zarebczan <thomas.zarebczan@gmail.com>
2022-02-07 13:35:17 -05:00
David Granado
ce903c9280
Patch to restore position upon returning to video until more fully fleshed out fix can be introduced (#817)
* Patch to restore position upon returning to video until more fully fleshed out fix can be introduced

* Add code to notify other open tabs of position saving

* Fix typo

* Wrap localStorage access in try/catch in event browser settings make it unavailable

* Remove formatting changes

* Move constant from 'pages' to 'player'

* Move dispatch out of try/catch

* Fixed typo
2022-02-07 12:51:26 -05:00
Thomas Zarebczan
fd1ee4f43c
recsys take 99 2022-02-04 18:38:42 -05:00
Rafael
df360f7ccc Fix player error 2022-01-31 17:27:41 -05:00
David Granado
f09c6d7a50 Fix play btn calcs as audio tag was not measuring as expected 2022-01-31 11:32:44 -05:00
Thomas Zarebczan
b3d9fe5473 Force stop event on dispose 2022-01-28 16:19:27 -05:00
mayeaux
373766c5b5
Fix vidcrunch on ios to only show ad when its scrolled to (#651)
* fix vidcrunch on ios to only show ad when its scrolled to

* clean up and optimize code
2022-01-10 22:21:55 +01:00
mayeaux
b822fbdac8
fix ios can autoplay bug (#640) 2022-01-06 22:20:42 +01:00
mayeaux
58bdcbd1ed
Reduce triple call to single call, improve video loading, fix embed play button being off-center (#546)
Lots of optimizations and cleanup for the player. If we run into any strange issues, can revert.
2022-01-06 14:28:27 -05:00
Anthony
bc514b1d5c fix lint errors 2021-12-15 15:00:28 -05:00
Anthony
c214209747 disable preroll ads 2021-12-15 15:00:28 -05:00
infinite-persistence
1766b418c6
Remove old mobile chromecast css hack
lbry-desktop--6844

This negates 49abbecb.

Now that we have a dedicated chromecast button, we don't need to hack Chrome's default cast button to appear on top of vjs-mobile-ui.  The hack no longer works anyway, since the CSS exposure has been deprecated around mid 2020 -- it is still available, but its abilities has become less and less.
2021-12-15 09:44:09 +08:00
infinite-persistence
561ed0ea23 -- experiment with forcefully closing the session on dispose 2021-12-10 14:16:03 -05:00
infinite-persistence
42a8f3180d Pass the title and channel name to Chromecast.
As noted in a comment, we need to be careful when adding props to `VideoJs` to avoid renders.

Used primitive strings (title, channelName) instead of passing the entire `claim`, which could have its reference invalidated.
2021-12-10 14:16:03 -05:00
infinite-persistence
4c84fde31b Add Chromecast support on Google Chrome. 2021-12-10 14:16:03 -05:00
mayeaux
82643b1f4a
Finish cleaning out DOM (#413)
* finish cleaning out dom

* lint
2021-12-02 13:22:51 -05:00
infinite-persistence
428c00901b
Fix double pause button in mobile (#408)
Restored css load-order that was changed from a recent refactor.
2021-12-01 22:06:22 -05:00
saltrafael
4fd4309829
add Player.js Support (#378)
* Reorder video.js imports and props

* Install player.js

* Add player.js adapter for video.js
2021-11-30 15:46:03 -05:00
infinite-persistence
f5f3b08cca
Debounce volume and muted state update.
## Ticket
189: Overall React Lag or Extra Re-renders / Volume slider laggy since v0.48

## The problem
Every redux update results in each mounted component's prop mapping function (the `select` and `perform` stuff) to be recalculated. This is normal per redux, but we do lots of heavy stuff there.

The slider was sending tons of redux update for the Volume and Muted setting.

## Changes
The redux volume/muted setting is just used to restore vjs to the user's setting on the next video, so it doesn't need to be updated immediately/constantly -- vjs keeps it's own video settings.  Debounced that action.
2021-11-29 23:12:38 +08:00
mayeaux
f2715fa97b
Adds GDPR support (#311)
* add gdpr support

* only run on production

* testing implementation

* just needs last touches then ready

* ready for merge

* add cookies to sidebar

* hide button when secureprivacy not available

* switch over to loading script as a react hook

* conditionally add secureprivacy script

* save gdpr status on session

* better design
2021-11-23 10:21:33 -05:00
infinite-persistence
3c4ccdd2fe
Kill makeSelectClientSetting
## Why
- No memo required (no transformation).
- `makeSelect*` is an incorrect pattern.

## Changes
- Replaced makeSelectClientSetting with selectClientSetting.
- Remove unused selectShowRepostedContent.
2021-11-23 12:29:53 +08:00
infinite-persistence
73f208923a
Optimize makeSelectClaimIsNsfw (and it's surrounding friends) 2021-11-16 10:14:01 +08:00
mayeaux
6546eaeb63
refactor ad code and dont show ads on embeds (#290) 2021-11-15 10:01:42 -05:00
infinite-persistence
93c28b24bb Remove desktop video start time analytics 2021-11-15 09:25:58 +08:00
infinite-persistence
6d217dbc50
Attempt to speed up sidebar menu for mobile (#283)
* Exclude default homepage data at compile time

The youtuber IDs alone is pretty huge, and is unused in the `CUSTOM_HOMEPAGE=true` configuration.

* Remove Desktop items and other cleanup

- Moved constants out of the component.
- Remove SIMPLE_SITE check.
- Remove Desktop-only items

* Sidebar: limit subscription and tag section

## Issue
Too slow for huge lists

## Change
Limit to 10 initially, and load everything on "Show more"

* Fix makeSelectThumbnailForUri

- Fix memo
- Expose function to extract directly from claim if client already have it.
2021-11-12 10:59:11 -05:00
mayeaux
529a9cbc40
Videojs component refactor (#240)
* pull out ads into its own file

* final touchup

* pull out lbry volume class

* using curried function

* coming along well

* almost done keyboard shortcuts

* pulling the guts out

* finishing keyboard shortcuts

* coming along well

* running but needs some testing

* almost done but could still use some testing

* all code working with some flow fixes needed

* fixing flow errors

* finishing flow errors
2021-11-12 09:56:46 -05:00
infinite-persistence
b8399f10b2
Fix lint/auto-formatting... 2021-11-01 15:23:08 +08:00
mayeaux
00d28fe26e
fix bug where scrolling on video player page changes volume (#154) 2021-10-28 10:46:24 -04:00
infinite-persistence
b7685a151d
Additional GA events via redux/lbryio hook
## Issue
85 Add additional GA events

## Approach
Instead of placing analytic calls all over the GUI code (no separation of concerns), try to do it through a redux middleware instead.

## Changes
- Updated GA event and parameter naming after understanding how reporting works.
- Removed unused analytics.
2021-10-22 10:56:43 +08:00
mayeaux
c782f73f30
switch macro (#102)
* switch macro

* allow skip and other options
2021-10-20 11:14:33 -04:00
Merge
30023422b8
Desktop cherry-pick: "7240 Integrate lbry redux and lbryinc" 2021-10-19 20:40:07 +08:00
mayeaux
5f55a3f128
use insecure mode (#74) 2021-10-14 11:55:46 +03:00
mayeaux
6727e2766b
fix channel value (#67) 2021-10-13 19:07:57 +03:00
mayeaux
c10fc675db
fix channel value (#66) 2021-10-13 19:00:32 +03:00
mayeaux
fa889112c5
Ads setup (#62)
* re enable preload ads

* switch macro to aniview

* point towards test server

* improving documentation

* bugfix and turn skip back on

* only run twenty percent of the time for unauthed users

* allow for embeds

* enable show internal feature

* working prototype

* seems to work well

* bugfix

* review old aniview setup

* change to production channelid

* final touchups
2021-10-13 11:04:03 -04:00
mayeaux
e3791aefdc
Send video bitrate and user bandwidth to Watchman (#7145)
* adding functionality to detect user download speed

* calculating bandwidth speed more intelligently

* saving download speed and updating it every 30s

* all the functionality should be done needs testing

* fix linting

* use a 1mb file for calculating bandwidth

* add optional chaining plugin to babel and get bitrate from texttrack

* allow optional chaining for flow

* ignore flow error

* disable bandwidth checking functionality

* fix flow error
2021-10-06 14:59:33 -04:00
jessopb
8a277e767a
revert embedNoEnd and modify preferEmbed end display (#7144) 2021-09-21 12:47:56 -04:00
jessopb
432c40fb0c
embed preferred no end (#7138) 2021-09-20 18:37:27 -04:00
saltrafael
1c59913e7a
Recommended changes (#7089)
* Fix floating

* Change makeSelectRecommendedContentForUri behavior
2021-09-16 16:00:44 -04:00
saltrafael
539cf780d7
Fix floating player issues (#7073)
* Fix Floating Player stopping on certain files

* Dont show additional player buttons from markdown and comments

* Fix markdown resizing for the same video playing

* Update changelog
2021-09-13 11:24:35 -04:00
saltrafael
e8d8dfa76b
Playlist fall out fixes (#7032)
* Add snack bar notification

* Fix and improve code

* Better handle paid content on playlists

* Fix menu options that show for unauth users
2021-09-10 13:27:21 -04:00