Commit graph

4832 commits

Author SHA1 Message Date
infinite-persistence
adc9575504
Category-metadata: add stub for Education + cleanup old categories (#735) 2022-01-19 09:04:15 -05:00
infinite-persistence
18c7469d25
Top Search: handle view count for Repost (#736)
## Issue
Closes "87 Repost - Top result should show followers properly"

The winning url for "bret" search is "lbry://bret", which is a repost.

## Change
We need to use the canon url to retrieved the fetched view count.
2022-01-19 09:04:01 -05:00
infinite-persistence
3338f9142c
ClaimList: fix missing key (#737)
## Issue
From the Draggable PR, the draggables retained the key but regular lists lost it.
2022-01-19 08:48:20 -05:00
infinite-persistence
b72127411c
Comment options: hide "Remove" when comment is removed. (#738)
## Issue
Closes 295 Livestream chat: Deleting comment that was already deleted by someone else, makes chat blank.
2022-01-19 08:42:39 -05:00
Thomas Zarebczan
24d53cd7d8
Formatting improvements (#731) 2022-01-18 13:30:43 -05:00
infinite-persistence
e4658bb044
Fix missing claims in large collection (#726)
## Issue
A huge list like http://localhost:9090/$/list/d91815c1bc8c80a1f354284a8c8e92d84d5f07a6 (193 items) often produces fewer results in the final rendered list.

## Cause
The same list of IDs was passed into `claim_search`, and we just increment the `page`. However, it seems like `claim_search` does not honor the order between each call, and some results from the previous page took the place of the results in the next page.  The total is the same, but there are now duplicates.

## Fix
When batching, slice the ID list ourselves to bypass the problem for now.
2022-01-18 09:33:01 -05:00
Thomas Zarebczan
e890e2f4f8
Fix crash 2022-01-17 23:24:59 -05:00
infinite-persistence
bdb83b5295
Commentron: *Delegates was failing silently
Added toasts to indicate errors instead of failing silently.
2022-01-18 10:46:18 +08:00
infinite-persistence
c1cb9345ad
Commentron: param updates for moderation.*Delegates
## Reason
https://odysee-workspace.slack.com/archives/C02FMSYF51B/p1642435815038000?thread_ts=1642129696.024400&cid=C02FMSYF51B
Due to unaligned parameters not compliant with Authenticate, ModAuthenticate APIs.

It will still work without this PR as there is a compatibility layer, but should use the correct params moving forward.
2022-01-18 10:43:58 +08:00
Thomas Zarebczan
df2ed078b3
Fix collection filter 2022-01-17 12:06:59 -05:00
Thomas Zarebczan
507d34dd8c
Odysee chat updates 2022-01-17 11:19:01 -05:00
infinite-persistence
7989020a04
Corrected mentioned_channels parameter name (#719)
Commentron json params are usually underscored instead of camel-cased.

Double-checked commentron code:

```
// MentionedChannel channels mentioned in comment
type MentionedChannel struct {
	ChannelName string `json:"channel_name"`
	ChannelID   string `json:"channel_id"`
}
```

The parameter should probably also be skipped instead of sending empty array, but leaving as-is for now since that is minor.
2022-01-17 08:44:45 -05:00
infinite-persistence
5dc1d416ef
CHANNEL_UNSUBSCRIBE: handle colon vs. hash uris (#706)
## Ticket
644 investigate following vs subscription preference data

## Issue
- iOS app uses colon for following/subscriptions.
- Front-end code handled the "colon vs. hash" for CHANNEL_SUBSCRIBE, but not for CHANNEL_UNSUBSCRIBE
2022-01-17 08:39:06 -05:00
infinite-persistence
ee71caf2bc
Comment api: re-format to single-line.
This will be an exception where the non-wrapped version is easier to read.
2022-01-17 14:34:41 +08:00
infinite-persistence
9743f4b49e
Move commentron error mapping to separate file 2022-01-17 10:25:06 +08:00
infinite-persistence
c1af19c7b9
Creative Arts strings 2022-01-17 09:28:02 +08:00
Thomas Zarebczan
62dd12ab78
New discord for rewards 2022-01-15 23:45:14 -05:00
Thomas Zarebczan
0b5f10c508
Allow hide chat on mobile 2022-01-14 18:51:33 -05:00
saltrafael
031a3a2f0a
Fix sidebar on mobile (#703) 2022-01-14 16:07:44 -05:00
saltrafael
a1a7ca321f
Fix livestream key listeners (#702) 2022-01-14 16:07:21 -05:00
saltrafael
ea9c7a4a27
[Live Chat] Break down componets for Page Layout + Add ability to Pop Out chat window + Hide chat option (#681)
* Refactor CommentBadge

* Refactor livestreamComment component

* Refactor and split livestreamComment CSS

* Refactor livestreamComments component

* Refactor and split livestreamComments CSS

* Remove never used spinner

* Refactor livestream Page

* Refactor page component

* Refactor livestreamLayout component

* Break apart livestreamComments into separate sibling components

- This helps separating LivestreamComments to deal with only the comments, and the LivestreamLayout to be used for its own Page as a Popout option, and also for a layered approach for mobile

* Create Popout Chat Page, Add Popout Chat Menu Option

* Add Hide Chat option

* sockety improvements

* Websocket changes

Co-authored-by: Thomas Zarebczan <thomas.zarebczan@gmail.com>
2022-01-14 15:24:16 -05:00
saltrafael
b810e07053
Fix doAbandonClaim (#699)
* Refactor doAbandonClaim parameters to only claim

- Gets txid and nout by default now, and passing claim allows using more data to verify ownership in case of txid:nout failing again
- Unused on modalRemoveCard
- Edited the comment on doCollectionDelete to explain better

* Fix doAbandonClaim failing to select my claim
2022-01-14 14:26:03 -05:00
saltrafael
83378174b7
Prevent Up and Down keys being overriden by MUI listeners when not in use (#698) 2022-01-14 12:55:42 -05:00
Thomas Zarebczan
53155bd7d6
Add back sorting on tags page 2022-01-14 12:39:33 -05:00
infinite-persistence
344da194ca
Resolve claim and stream types when there is a filter (#696)
* Resolve claim and stream types when there is a filter

## Symptom
Channel Page 'Content Type' filter not working

## Issue
The Advanced Filter work by placing a `?content=` URL param. The list component then parses it and makes the `claim_search` params accordingly. But:

1. There is a mix up in how the list component treats `?content=`.
    - The original code seems to treat this as a way to define the type externally but only for a list without `claimType` defined via code. In other words, if `claimType="something"`, `?content=` is ignored.
    - On the other hand, the Advanced Filter relies on `?content=` being used.

2. `?content=` is then split between `claimType` and `streamType`. The current code does not check if the split makes sense, e.g. if `?content=channel` and `streamType=['video']`, these 2 are incompatible and produces no results.

## Change
1. I'm not really sure what's the original intention, but let's just make `?content=` as an override/filter.

2. `?content=` should probably be limited to always be a subset of `claimType` and `streamType`. But this seems complicated to do, so for now let's just make always override/filter everything.  For that, we need to make sure the filtered `claimType` -- `streamType` combo makes sense.

* Fix 'Channel' filter not working in Wild West

## Cause
The Wild West list defines `release_time` to be 1 week ago. As long as this parameter exists, a channel `claim_search` produces no results (I thought channels have creation dates?). That is why an unfiltered Wild West never showed Channel Tiles.

## Change
The existing `release_time` handling does seem to hint that we should not set the parameter when searching for Channels. Expanded that to consider the final (filtered) claim type, not just the original.
2022-01-14 11:06:13 -05:00
saltrafael
f3892325ce
Find and Pass mentioned channel name + claim id on comment_create (#690) 2022-01-14 09:50:09 -05:00
infinite-persistence
0d6cd21457
Fix ignored 'Content Type' filter (#694)
## Issue
After enabling Advanced Filter in Category Pages, the 'Content Type' filter only works for "repost/video/list".

## Root-cause
When `streamType` is not provided, it defaults to 'Video|Audio', making it always "defined":

```
streamType = SIMPLE_SITE ? [CS.FILE_VIDEO, CS.FILE_AUDIO] : undefined,
```

This seem to override the purpose of `defaultStreamType`, which will not be used unless the client explicitly set `streamType=null`, which currently is only being applied for `RECENT_FROM_FOLLOWING[]`.

```
  const streamTypeParam =
    streamType || (CS.FILE_TYPES.includes(contentTypeParam) && contentTypeParam) || defaultStreamType || null;
```
2022-01-13 22:03:04 -05:00
infinite-persistence
7affa8b7a1
Fix advanced filter showing up in Wild West (#695)
Behavior we want:
- hide Advanced Filter for Wild West
- show Advanded Filter & Filter for everything else
2022-01-13 22:00:41 -05:00
Thomas Zarebczan
e2f414f98c
filtering improvements (#692)
+ limit wild west to 3 claims per channel
+ hide language for now until we can sync homepages + settings
2022-01-13 16:13:49 -05:00
saltrafael
e1bbd9984a
Fix mentioning with enter (#691) 2022-01-13 13:36:07 -05:00
infinite-persistence
4ae1df4eb9
Thumb: make CDN limit an env so we can change easily 2022-01-13 13:18:41 +08:00
infinite-persistence
eb420af865
Thumb Generator: switch to jpeg + lower quality when needed
The quality API doesn't work on the default PNG but works on JPG.

- Switching to JPEG (100%) produces a smaller image than the default PNG. This covers most scenes.

- For some scenes, the size could still be larger than 2MB, so retry with JPEG (80%). For a 1080p image, this action produces the file at <1MB range. The quality still looks ok, I think.
2022-01-13 12:50:26 +08:00
Thomas Zarebczan
9e70629ada
Fix comment disabling on MD (#685)
Also restore reactions
This is only an internal tag
2022-01-12 16:26:28 -05:00
saltrafael
2575c5d448
[Playlist] Pull in sorting changes from desktop + Add Drag-n-Drop + Handle unavailable/deleted claims (#641)
* Add ordering Icons

* Refactor doCollectionEdit

- It required claims as parameter, when only uris are used to populate the collection, so that was changed to pass down the uris instead.
- There were unused and mostly unnecessary functions inside, for example the parameter claimIds was never used so it would never enter the claimSearch function which again would be used to generate uris, so it's better to just use uris as parameter

* Add List Reordering changes

* Add toggle button for list editing

* Add toggle on content page collection sidebar

* Enable drag-n-drop to re-order list items

https://www.youtube.com/watch?v=aYZRRyukuIw

* Allow removing all unavailable claims from a List

* Fix <g> on icons

* Fix section buttons positioning

* Move preventDefault and stopPropagation to buttons div instead of each button, preventing clicking even if disabled opening the claim

* Change dragging cursor

* Fix sizing

* Fix dragging component

* Restrict dragging to vertical axis

* Ignore shuffle state for ordering

* Fix console errors

* Mobile fixes

* Fix sidebar spacing

* Fix grey on mobile after click
2022-01-12 14:14:12 -05:00
infinite-persistence
431f55ef26
Delete pixel experiment (#683) 2022-01-12 10:14:44 -05:00
infinite-persistence
3d246a30ba
Fallback to main language (xx) when sub-language (xx-yy) is not supported. (#682)
## Issue
656 Automatic language detection can't recognize de-DE as de

## Note
We do fallback to the main language, but seems like the code got lost ... not sure when, but probably during the CN/TW or PT-BR support. The refactor in  81e47300 still did that, but the refactor was reverted due to some compilation issue (should revisit that someday).

## Change
Put back equivalent code.
2022-01-12 09:46:57 -05:00
Dan Peterson
1f596e963d
Make sure to specifically query for streams (#671) 2022-01-11 12:08:55 -05:00
Dan Peterson
dcfb64d907
Make the hide setting optional and don't use it on the channel page. (#670) 2022-01-11 11:46:13 -05:00
infinite-persistence
e58ddbc809
View/Follower count: only use compact when > 10k (#664)
* Tooltip: add 'followCursor' and 'placement' option

When used on a `<span>` with short text but large empty area, the location of the tooltip was at the bottom-center of the area, which isn't ideal.

I think 'followCursor' should be the default, but making it optional for now to minimize testing.

Also added the 'placement' prop -- for the span case again, the mouse cursor is blocking the tooltip.

* View/Follower count: only use compact when > 10k

## Issue
Received complaints -- some people prefer to see full resolution.

## Changes
- As a compromise, we'll only apply the compact notation when the value is greater than 10k, with the exception of Tile View Count, where we'll always apply it due to space limitation.
- Also added Tooltip for Follower count.

## Fixes
- The string was always in 'en' locale in some instances, so it wasn't grouping up digits properly in Japanese (groups of 4), for example.
2022-01-11 11:42:12 -05:00
Dan Peterson
1a57b02f80
Enable the new scheduled tag filtering and set the buffer back to 35 minutes (#669) 2022-01-11 11:33:33 -05:00
infinite-persistence
3bba4ab630
Fix infinite scroll when "Upcoming livestream" appears (#665)
## Issue
When "Upcoming livestream" appears in a list, infinite scroll stops working.

## Cause
The difference between `mainEl.getBoundingClientRect().bottom` and `window.innerHeight` became slightly greater than 0.5, so it was deemed as "haven't reached the bottom".

## Change
Coincidently, I've been wanting to make the inf scroll load earlier (instead of after reaching the absolute bottom) to make the experience smoother, so added a 200px threshold, which is roughly the height of a tile. This gets us the new behavior while also fixes the original problem.
2022-01-11 08:26:44 -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
Max Kotlan
c9108f530c
mobile menu fix animation close on page load (#652) 2022-01-10 13:14:46 -05:00
infinite-persistence
0147af156c
File page: use compact follower count 2022-01-10 11:13:33 +08:00
infinite-persistence
1d4e1296ec
File page: use compact view count (w/ tooltip for full res) 2022-01-10 11:05:49 +08:00
infinite-persistence
df4d142370
Factor out 'toCompactNotation' 2022-01-10 10:42:56 +08:00
infinite-persistence
8507d07d3e
Remove incorrect comments
- activeChannelClaim is the comment creator, not receiver.
- doSeeNotifications marks a notification as "seen", and not "send a notification".
- Removed comments that are just explaining the syntax.
2022-01-10 09:18:11 +08:00
Thomas Zarebczan
ac93e0c22c
2MB max thumb size messaging (#650) 2022-01-07 14:39:27 -05:00
mayeaux
b822fbdac8
fix ios can autoplay bug (#640) 2022-01-06 22:20:42 +01:00
Dan Peterson
a89cb17ce4
Add horizontal layout (#636)
* Test out a horizontal scroll for upcoming (tile only for now)

* - add support for list layout
- add following label on home page
- clan up css and naming conventions

* Update header type + show only if scheduled streams are showing
2022-01-06 16:13:26 -05:00