Commit graph

3034 commits

Author SHA1 Message Date
Rave | 図書館猫
2762d43224
Restructure header navigation (#1611)
* Restructure header navigation

* Hide theme button in guest mode

* Update channel selector width and navigation top in header
2022-06-03 09:43:31 -04:00
Rave | 図書館猫
81eddb2b5d
Publish revamp (Part 1) (#1593)
* Rearrange fields

* Autocomplete title

* Fix class position

* Hide deposit behind advanced settings

* Redesign additional options

* Redesign price section

* Update price section

* Redesign tags section

* Fix title edit

* Make with dynamic

* Redesign thumbnail section

* Redesign description section

* Resedign file section

* Polish sections

* Adjust help text

* Clear title on form reset

* Adjust price section

* Fix help color in light theme

* Polish

* Mobile adjustments

* More mobile adjustments

* Remove border-bottom from publish rows

* Redesign date section

* Adjust some details

* Adjust clear button

* Adjust channel selector on mobile

* Adjust post save button position

* Adjust browse button color

* Adjust channel picker on mobile

* Eenable announcement page

* Remove file title, remove space, redesign licence section

* Fix edit form, existing claim warning, missing title warning

* Adjust light theme

* Adjust icon collor in button
2022-06-03 09:28:12 -04:00
Thomas Zarebczan
547781c07c
Update messaging around bitrates / resolution
Allow for higher bitrates, but still recommend transcode over 8mbps until we have transcode on upload.
2022-06-02 14:47:50 -04:00
Thomas Zarebczan
328c8938c6 Use separate ad for file pages 2022-06-02 13:02:38 -04:00
infinite-persistence
70ddd08df6 Show Sticky in Content and Channel Page for incognito
https://odysee-workspace.slack.com/archives/C02G20Z2AEL/p1654171314724029?thread_ts=1654089384.715699&cid=C02G20Z2AEL

Content: not showing ads for signed-in users because it interferes with commenting.

Channel: same behavior as Categories (i.e. show is not Premium+).
2022-06-02 10:49:42 -04:00
infinite-persistence
16da04e6b9
SnackBar: pause dismiss timer when mouse is over it 2022-06-02 15:56:45 +08:00
infinite-persistence
d89e04942b
Tweak tip/boost toast message
- Split the friendly text (non-essential) to `subMessage`.
- Put a link to the wallet history for all these tipping toasts.
- Don't say "tip" for the Wallet Send action (Issue_1605)
- Make the link font-size smaller than the main text.
2022-06-02 15:36:05 +08:00
infinite-persistence
f69097b488
Don't block entire router while fetching Categories
This is a follow up for 2b60fe95

## Issues
- Not every page needs the Category data, so only block for Category pages.
- `categoryPages.length` was rendered as a number while blocking for the fetch.

## Change
It's a chicken-and-egg thing because we don't know what the category path is, but fortunately categories and internal pages start with `/$/`, so we can make a reliable guess. The other internal pages would have matched the defined routes and would not reach this function.
2022-06-02 14:11:52 +08:00
Thomas Zarebczan
b6eb580c82 Revert "Recsys: determine the clicked index based on raw results instead of rendered order"
This reverts commit e4214b1c1b.
2022-06-01 09:55:56 -04:00
infinite-persistence
32f0d1d7a1 Tip: show modal instead of toast when timeout
## Issue
The toast wasn't good enough as the user might miss it and attempt to re-send.

## Change
- Change the tip timeout from Toast to Modal.
- For the case of Comments, add additional info about being unable to re-link the txid to the comment for now. Not really useful to the user, but better than nothing.
2022-06-01 08:40:39 -04:00
infinite-persistence
e4214b1c1b Recsys: determine the clicked index based on raw results instead of rendered order
## Ticket
1606

## Issue
The displayed order of the recs are often re-adjusted -- viewed content are pushed to the bottom to avoid auto-play-next from picking it up again. This was causing recsys to be confused, because the click order does not correspond the results.

## Change
Refactored the selector we can grab the raw results and use that as the index reference.
2022-06-01 08:32:37 -04:00
Anthony
9b2cc7eb79 dont show subs for ios and correct position for actual subs 2022-05-31 10:41:31 -04:00
infinite-persistence
0bcea943d5 Re-implement/enable sticky ad
## Ticket
1583: "add incontent ads to category/channel pages (break up every X claims?), or add back bottom ad in those areas."

## Behavioral changes
- Hide when in homepage (as currently we have ads between categories).
- Fix the light theme (it was transparent).

## Code changes
- While an Effect is the 'right' choice given that there is no jsx to mount, the need to prop-drill from the parent was getting a bit annoying, so converted to a Component instead.
- Remove the delay for Core Vitals avoidance for now -- seems to make the sticky less likely to serve an ad.
- Now that the membership state is correctly populated for incognito (see 9d830615), there is no more need to check for `isAuthenticated`.
2022-05-31 10:34:38 -04:00
infinite-persistence
a2f15b8348
Player: fix i18n for 'Auto' 2022-05-31 18:12:51 +08:00
Rave | 図書館猫
ea3d8e01ef
Design patch 22-05-31 (#1598)
* Redesign form elements with background

* Adjust list ads

* Fix progress bar in mini player

* Fix progress bar on mobile

* Fix progress bar in theater mode

* Redesign repost modal

* Update channel selector in modal

* Remove border radius from embedded media

* Adjust quality selector

* Adjust updated player theme for light mode

* Rename wrapper class
2022-05-31 11:14:59 +02:00
Raphael Wickihalder
9eda81db58 Replace state with ref for uriBuffer 2022-05-31 10:38:39 +08:00
Raphael Wickihalder
99a36b6bd6 Clean code 2022-05-31 10:38:39 +08:00
Raphael Wickihalder
c6c824c059 Fix grid with adnimation 2022-05-31 10:38:39 +08:00
infinite-persistence
29431b1074
Revert "Test 'Rich Test' error screenshot"
This reverts commit 8f35f53e7a.
2022-05-30 22:50:40 +08:00
infinite-persistence
8f35f53e7a
Test 'Rich Test' error screenshot
Verifying whether the result screenshot for errors are cached.
2022-05-30 22:28:22 +08:00
Raphael Wickihalder
8b1927b5dd
Move channelTitle to view 2022-05-30 07:27:41 +02:00
Raphael Wickihalder
e4db2d401b
Remove channelName prop 2022-05-30 07:15:07 +02:00
kt programs
c16fb8c906 Fix spelling of SORT_ASCENDING in search constants 2022-05-30 12:04:20 +08:00
Raphael Wickihalder
a7bbb464d6 Clean code 2022-05-29 09:18:57 -04:00
Raphael Wickihalder
ca135cc7f8 Integrate media session api 2022-05-29 09:18:57 -04:00
Raphael Wickihalder
2b60fe957f Get rid of 'content not found' page in categories 2022-05-29 09:11:35 -04:00
infinite-persistence
c71c8e1cd0
Remove bottom-ad for now
- Light theme issues
2022-05-27 20:49:56 +08:00
infinite-persistence
bf7dcbe344
Bottom-Ad: change to only hide for Premium+
Previously, we hide when authenticated.

We still need the `isAuthenticated` flag, because `hasPremiumPlus` stays at the unfetched (`undefined`) state for Incognito.
2022-05-27 20:48:52 +08:00
infinite-persistence
4ae3fe7ea0
Make Category & Channel pages re-fill ads after scrolling every 2 pages 2022-05-27 20:48:52 +08:00
infinite-persistence
cc0ed44bf6 Homepage: add "reset" + 'hideByDefault' categories
Requires a related commit from the homepages repo.

## Changes
- Add ability to reset the sort order.
- Make 'News' and 'Wild West' a "hideByDefault" category. It can be made visible in the homepage from the customization dialog.
2022-05-26 10:59:31 -04:00
Thomas Zarebczan
786d9d0253
optimize premium image + add smaller 2022-05-26 09:22:23 -04:00
Rafael
11bdb6a872 Fix wait for prefs on default channel set 2022-05-25 11:52:48 -04:00
infinite-persistence
58167210ea Geoblock: show warning for own content
## Issue
Contents aren't block if you own them, but need to tell creator that is it blocked for others.

## Change
- Show a banner on Content and Channel Page for this scenario.
- Hover tooltip is available for the full text. For mobile, tapping it reveals the message.

Note that this only applies to the locale from where the creator is viewing it from. We can ignore locale, but would then need to display _all_ geo-restrictions related to the content in a list.
2022-05-25 08:51:08 -04:00
infinite-persistence
a4add6eab6
Fix geoblocked items appearing in wunderbar suggestion popup
This list is not using ClaimPreview or ClaimPreviewTile, so the filtering was missed.
2022-05-25 14:37:09 +08:00
infinite-persistence
4aa94a7bfd
Fix variable name confusion
Per convention, 'ByUri' would mean it's the array/object that is storing the entire list, but this is actually the specific entry.
2022-05-25 14:30:41 +08:00
infinite-persistence
6d6d95237a 1318: Persist recsys data for send after tab close
- Add ability to store `entries` into Redux.
- Sync to redux in the same interval as when playing position is saved (re-use timer).
- On startup, send any stashed entries and clear them.
2022-05-24 13:52:50 -04:00
saltrafael
f9d1b8de8e
Automatically set default channel on sign up (#1559) 2022-05-24 06:18:26 -04:00
saltrafael
3918906605
Remove clearPosition functions for playlists (#1560)
- Let the position be cleared at the end like regular videos
2022-05-24 06:07:46 -04:00
infinite-persistence
d5c964c208
Additional geoblock support (#1552)
* Remove claim from channel page when geoblock conditions hits

Ticket: 1100

* Handle geoblocked channel page

## Ticket
1100

## Issue
"If a channel is geoblocked, the entire channel page (even showing titles, etc. would be against the law)"
2022-05-24 00:15:18 -04:00
Rafael
600d9a0f94 Fix Drag-and-drop error 2022-05-23 14:31:43 -03:00
saltrafael
b854e32f5c
Fix comment sort change (#1556) 2022-05-23 11:34:32 -03:00
infinite-persistence
cf700c3627 Comment: remove the muted prop
Since the comment list is pre-filtered and includes the muted list, I think this prop will never be true?
2022-05-23 18:37:19 +08:00
Rave | 図書館猫
d207117e5d
Grid patch v1 (#1555)
* Patch v1
2022-05-23 11:32:57 +02:00
infinite-persistence
8c06dab10f
ClaimPreviewTile: fix render violations and onHidden logic
## Issues
- Not safe to call the parent callback from the render function. It must be called from an effect or
- `onHidden` is only called when blacklisted, but it can also be hidden from other circumstances.
  - While those other circumstances doesn't apply for FYP (the first client that relies on `onHidden`, it's incorrect from a code perspective, unless it is renamed to `onBlacklisted`.

## Change
- Move the callback execution into an effect.
- Ensure `onHidden` is for all situations that it is hidden.
2022-05-23 14:49:53 +08:00
infinite-persistence
cde0c0b2a8
ClaimPreview: restructure
Try to gather the hide/show logic
2022-05-23 14:49:52 +08:00
infinite-persistence
287eb38e7a
ClaimPreviewTile: restructure (no functional change)
Effects cannot be defined after the render function returns early, so it was not possible to add new effects when the derived variables that it depends on are way down below.
2022-05-23 14:01:54 +08:00
infinite-persistence
8eb6ffd2b9
Rename 'community_channels.js' -> 'channels.js' for re-use
Re-using this file to put more hardcoded channels.
2022-05-23 10:53:23 +08:00
Rafael
e045d7a2ad Fix iframe class 2022-05-20 09:36:29 -03:00
saltrafael
6136ae7d73
Fix touch overlay max-height on mobile (#1541) 2022-05-20 08:23:37 -04:00
Thomas Zarebczan
9a247d3c9f
Mature fixes 2022-05-19 17:40:31 -04:00
saltrafael
28b9e2a4d3
Fix fetch behavior when switching claims (#1533) 2022-05-19 13:54:45 -04:00
infinite-persistence
14a11aa78a
Clear announcement history using window.clearLastViewedAnnouncement()
This helps testing, and can be eventually removed. No harm leaving it there, though.
2022-05-20 00:04:07 +08:00
infinite-persistence
3719a73c81
Add announcement modal and open it after prefs sync'd.
- Don't want to show it in Incognito.
- Only show it in when entered from homepage, or in the Help page.
- Record the hash of the viewed announcement and update the wallet with it.
2022-05-20 00:04:06 +08:00
infinite-persistence
b733215c5f
PublishFile: fix render function violation (#1518)
* PublishFile: fix render function violation

Per doc:
> A React component should not cause side effects in other components during rendering.

Even in own render function (allowed to call), it should be avoided as it could cause infinite loops.

* PublishFile: fix useEffect infinite loop due to bad dependency

## Issue
One of the effects was adding an internal wrapper function as a dependency. As this is a functional component, the wrapper is re-created on every render and would spark the effect. That effect also updates redux (depending on the code path), so we end up in a loop.

## Change 1
Two options to fix the dependency:
1. Just remove the wrappers from the list, since we "know" it is essentially the same function (i.e. it's not function-variable that could point to something else at runtime).
2. Peek into the wrapper and determine what are the actual dependencies (usually props or data derived from props).

Solution 2 is the norm.

Aside: wrappers are usually the root-cause of incorrect dependencies, because they mask away the actual code. Need to always peek into it.

## Change 2
Next, change the dispatch-to-props map from function version to object version so that we have stable references to the actions. The object version is also preferred when we don't need to make any customizations to the actions.
2022-05-19 10:41:32 -04:00
mayeaux
bb065eb408
dont run image preview on mobile (#1527) 2022-05-18 16:50:30 -04:00
Rave | 図書館猫
746d321dfe
Remove Premium+ Tiles when Premium+ is active (#1525) 2022-05-18 20:51:15 +02:00
infinite-persistence
53079d92b6
Move PremiumPlusTile into Ads (#1522)
* Move `PremiumPlusTile` into `Ads`

This saves the need to repeat the logic everywhere.

* Add option to disable fallback.
2022-05-18 19:52:46 +02:00
infinite-persistence
855d3dae01
ClaimList: fix infinite effect loop (#1523)
`tileUris` is being used as an effect dependency, but it gets re-created on every render (same content, different reference), so the `setUriBuffer` effect ended up in a loop.
2022-05-18 13:30:07 -04:00
saltrafael
b0b2056d78
Allow chat to be resized (#1517)
* Allow drawer to be resized

- Basically re-writes the drag behavior into the Drawer component instead of using SwipeableDrawer, getting more flexibility of where to stop and what to do
- More improvements like the backdrop effect, animations and window resize behavior

* Fix console errors

* Close drawer on unmount so other pages dont load open

* Allow livestream chat to be resized horizontally

* Fix mobile browser size

- address bar etc could be on the way

* Handle popout chat

* Fix pause with floating player
2022-05-18 12:15:12 -04:00
mayeaux
0cf8c181df
Preview image thumbnails (#1514)
working example

use my forked package

touchups to presentation

Make progress bar thumbnail sprite pixel perfect

add vtt path

fix progress bar a bit

add a black background

use odysee team package

fix two issues for merge
2022-05-18 18:02:02 +02:00
Rave | 図書館猫
ffdb5abf63
Tile Grid Revamp (#1502)
* Save

* Save

* Add pulse

* Adjust footer ad

* Adjust tile ad

* Adjust tile ad hover

* Fix premium badge alignment in tile grid

* Adjust livestream icon

* Adjust livestream icon

* Save scheduled livestreasm & tile ad

* Fix scheduled callback

* Fix playlist icon size on file page

* Fix grid distortion in 3 & 4 column layout

* -

* Fix grid on category & channel page

* Fix Premium Plus Grid

* Add custom tile for adblockers

* Reset env

* Remove collapsed tiles

* Remove setLoaded on scheduled livestreams page

* -

* Make isHidden optional

* Remove px

* Review adjustments

* Inject Premium+ ads

* Fix injection

* Fix injection when using the last tile

* Fix injection when using the last tile

* Enable stripe dev

* Create PremiumPlusTile component and add list view design

* Create PremiumPlusTile component and add list view design

* Adjust ads in list view

* Remove setState from render loop

* Clean code

* Fix livestream margin in list view

* Rewrite & tune some logic - Homepage & Channel page

* Clean details...

* Clean details...

* Requested review changes

Signed-off-by: Raphael Wickihalder <raphael.wickihalder@odysee.com>

* Requested review changes

Signed-off-by: Raphael Wickihalder <raphael.wickihalder@odysee.com>
2022-05-18 13:16:35 +02:00
Thomas Zarebczan
1d61d80009
more analytics + fixes (#1476)
more analytics + refactor

- passes player with time to start (until we move this api to watchman)
- supports livestream metrics for buffering
- fixes bug with buffering over 10 second period
- less head calls by moving to videojs-events

* review fixes
2022-05-17 10:47:44 -04:00
infinite-persistence
be7193382c
Fix remaining untranslated ctrls
Ticket: 1507
2022-05-17 16:33:11 +08:00
infinite-persistence
5e944499f3
Refactor "Theather Mode" 2022-05-17 16:16:39 +08:00
infinite-persistence
535d02807a
Refactor "Autoplay Next" 2022-05-17 16:16:38 +08:00
infinite-persistence
36ddc69c13
videojs: refactor i18n (breaking up 'events' file)
## Issue
I couldn't find where the i18n went because the "events" refactor is just as confusing as the original -- unrelated things are still lumped together in a file.

Also, factoring based on events isn't useful -- it is features that drive what events are needed, not the other way around. This forces features to register events here, and do other things elsewhere? It will be more intuitive to have a one-file-per-feature structure.

## Change
Use existing frameworks to encapsulate things to manageable units/features:
(1) the React useEffect files (can be used isolate out React features like 'tap-to-mute' handling).
(2) the videojs plugins framework.
2022-05-17 16:16:37 +08:00
Rafael
75df2a5f13 Also add RSS Url 2022-05-16 06:36:50 -04:00
Rafael
7c68fd1e61 Remove active livestream condition
- meaningless since its supposed to be a permanent link either way
2022-05-16 06:36:50 -04:00
Rafael
26d7e9a2b6 Add share buttons on channel page 2022-05-16 06:36:50 -04:00
Rafael
239bde0752 Also add support for embeds 2022-05-16 06:36:50 -04:00
Rafael
6b2427768c Add ability to link to latest or current live channel file pages
- and some changes to activeLivestream redux since it would return undefined if fetching and no claim, so now it returns null when no activeLivestream is found
2022-05-16 06:36:50 -04:00
Rafael
bf158ad696 Refactor
- some cleanups
- uri was being parsed the same way in different places, so do it only once for simplicity
2022-05-16 06:36:50 -04:00
saltrafael
b75a4014b6
Re-design comment threads (#1489)
* Redesign threadline and fetching state

- threadline goes right below channel avatar, mimicking reddits implementation, has a increase effect on hover and is slimmer, creating more space for comments on screen
- fetching state now replaces show/hide button, also mimicking reddit, and now says that it is loading, instead of a blank spinner, and also improves space a bit

* Redesign comment threads

- Allow for infinite comment chains
- Can go back and forth between the pages
- Can go back to all comments or to the first comment in the chain
- Some other improvements, which include:
- add title on non-drawer comment sections (couldn't see amount of comments)
- fix Expandable component (would begin expanded and collapse after the effect runs, which looked bad and shifted the layout, now each comments greater than the set length begins collapsed)
- used constants for consistency

* Fix replying to last thread comment

* Fix buttons condition (only on fetched comment to avoid deleted case)

* Fix auto-scroll

* Bring back instant feedback for Show More replies

* Improve thread back links

- Now going back to all comments links the top-level comment for easier navigation
- Going back to ~ previous ~ now goes back into the chain instead of topmost level

* Clear timeouts due to unrelated issue

* Fix deep thread linked comment case and more scroll improvements

* More minor changes

* Flow

* Fix commentList tile style

* Fix long channel names overflowing on small screens

* More scroll changes

* Fix threadline

* Revert "Fix long channel names overflowing on small screens"

This reverts commit e4d2dc7da5861ed8136a60f3352e41a690cd4d33.

* Fix replies fetch

* Revert "Fix replies fetch"

This reverts commit ec70054675a604a7a5f3764ba07c36bf7b0f49c8.

* Cleanup and make smooth

* Always use linked comment on threads

* Cleanup

* Higlight thread comment

* Fix comment body styles
2022-05-16 06:22:13 -04:00
infinite-persistence
13b59037a6 1317: Log and send totalPlayingTime
The current time is quantized to 1s, and `lastTimestamp` is used to prevent duplicate counts because `timeupdate` is fired at ~250ms intervals.
2022-05-12 18:35:20 -04:00
Thomas Zarebczan
ac0ec4794a
Fix quality selector 2022-05-12 11:48:21 -04:00
Rafael
b2763e4bf0 Fix Kebab 2022-05-12 11:34:05 -04:00
infinite-persistence
40a59c53d4
Don't show wallet value until prefs are ready
... because preference might be "Hide wallet = true". This eliminates the gap during login or boot up that temporarily shows the wallet balance.

Ticket: 1365
2022-05-12 14:36:06 +08:00
Raphael Wickihalder
4fcaf7ba2f
Fix timestamp input type 2022-05-11 18:56:33 +02:00
Raphael Wickihalder
57eae71d12
Fix timestamp input pattern 2022-05-11 18:44:01 +02:00
Raphael Wickihalder
b0e213a2b5
Fix timestamp input pattern 2022-05-11 18:31:18 +02:00
infinite-persistence
c572891590 Update /$/live to use latest API
1480
2022-05-11 07:57:44 -04:00
Thomas Zarebczan
18ec09c5b0
clear up about page 2022-05-10 14:10:31 -04:00
Rafael
17868635bd Bring back default channel functionality
- consolidate cases that need to auto set an active channel (like edit page) into channelSelector component
- also for consistency since some components would do it with button click and others on page mount
- prevent clear function on those pages (kind of a manual process to insert each page into the router condition)
2022-05-10 09:06:10 -04:00
Rafael
0afeaa6223 Remove active channel cleanup function
- reverts active channel functionality back to how it was previously, making the default channel simply a sync fallback and removing all complexity and confusion
2022-05-09 07:50:44 -04:00
Rafael
adc3c06803 Fix header icon active channel 2022-05-09 07:50:44 -04:00
Thomas Zarebczan
86819b6876
update background URL 2022-05-06 14:28:04 -04:00
infinite-persistence
dae78c488f Stacked toast view
From the previous commit, we are now showing toasts in the reverse order (latest to oldest).

Next, extend the "hide snack" timer to handle multiple snacks. It will dismiss them one by one, restarting itself until no more toasts.

Show a stacked GUI when there are multiple toasts.

Users can still manually dismiss the toasts.
2022-05-06 13:53:39 -04:00
infinite-persistence
208b701998 Fix comment channel not checked in Livestreams
## Change
Moved the fetch from `CommentList` to `CommentCreate` instead, which is used by both Content and Livestreams comments.
2022-05-06 11:31:42 -04:00
infinite-persistence
26f9cf3a4f Undo the channel-clamping and let user figure out from Toast
Several issues with the clamping behavior:
- Problems trying to sync with the activeChannel setting.
- Corner-cases like unable to un-react because the comment and react channel was different; global mods not be able to change channels to do certain actions.

Just let the user know what are the channel(s) that they used to comment previously in the Toast.
2022-05-06 11:31:42 -04:00
Thomas Zarebczan
6cc85cd39d minor copy changes 2022-05-05 15:47:01 -04:00
Raphael Wickihalder
4022273408 Add code review requests 2022-05-05 15:47:01 -04:00
Raphael Wickihalder
42b456307f Save new signup flow 2022-05-05 15:47:01 -04:00
Raphael Wickihalder
4c1bf27dc1 Save thumbnail uploader 2022-05-05 15:47:01 -04:00
Rafael
f191cf0b88 Fix default channel changing with active channel on header 2022-05-05 11:24:22 -04:00
Rafael
371ce4a7ff Style fixes 2022-05-05 11:24:22 -04:00
Rafael
33826ea652 Fix style shift 2022-05-05 11:24:22 -04:00
Rafael
ca755d37b3 Fix console errors 2022-05-05 11:24:22 -04:00
Rafael
5e7fac563f Move clear function to page switch 2022-05-05 11:24:22 -04:00
Rafael
aa86815418 Fix menu link 2022-05-05 11:24:22 -04:00
Rafael
f2558f19f9 Add a clear function when a channel selector component is used
- this way, you can choose an active channel for something like commenting but when that component is unmounted, you always go back to the default channel (like leaving page)
2022-05-05 11:24:22 -04:00