Commit graph

608 commits

Author SHA1 Message Date
infinite-persistence
99b446a8fe Use baked-in homepages until service is moved elsewhere
The code currently supports both the baked-in homepages, as well as fetching from `/$/api/content/v1/get`.

As the latter is currently a circular round-trip, just use the baked-in version until the service is moved elsewhere. Loading performance will be better.
2022-04-13 13:38:04 -04:00
Thomas Zarebczan
17d5d5c73b partial new livestream api support 2022-04-13 11:52:00 -04:00
infinite-persistence
751a9253e9
Hush developmental app-string fetch errors for dev-server 2022-04-13 22:23:09 +08:00
infinite-persistence
5288fb3de8 Fix signout sequence not cleaning up correctly
Potentially closes 1319

## Note
- `persistor.purge` returns a promise, we should wait for the resolved results before reloading, instead of just adding an arbitrary `setTimeout`.
  - Perhaps the `setTimeout` method is to ignore a super-long or hanged purge (not sure), but it wouldn't be right since it would end up in a limbo state.
- Log errors to get clues for future.
- Reduced code by moving the reload to `finally`.
2022-04-11 07:36:10 -04:00
infinite-persistence
4b93be049c OwnComment Page: deleting comment shows failure despite successful
## Change
Due to "Own Comments" being implemented the same way as "Discussion Page", the comment lookup did not work for the abandoning case.

Just skip the local cleanup of `byId` -- it doesn't matter, as the GUI uses `selectCommentsForUri` to grab the per-channel comments, so it would still disappear in the GUI immediately.
2022-04-08 12:50:00 -04:00
infinite-persistence
12a59708e4 doCommentListOwn: clean up docs; add limit assertion 2022-04-08 12:50:00 -04:00
Rafael
65b9906086 Add dynamic player aspect ratio resizing 2022-04-07 11:44:25 -04:00
infinite-persistence
79a093eb28 Remove abandoned claim from Uploads Page
## Issue
Ticket: 108

## Interesting
Uploads Page uses `claim_list`
Channel Page uses `claim_search

A second `claim_list` would instantly show updated results, but `claim_search` takes a long while to reflect the deletion.

## Change
This PR only handles the `claim_list` (Uploads Page).

The `claim_search` version would be troublesome to handle. If a refresh would bring back the results (due to the `claim_search` slow update behavior), we would need to store the deleted claim persistently. Then ...
  - Store where? rehydrate?
  - When to clear?
  - How to make each `ClaimList` filter this out without polluting the code? etc.
...will be messy. Feels easier to "fix" at the `claim_search` level to make it update faster (maybe a command to clear cache at server or something).
2022-04-04 07:08:46 -04:00
infinite-persistence
89feddee0d Publish: handle failed 'notify' at the server
Ticket: 1256

For `notify`, "file is currently locked" and "no such file or directory" is indication that the previous "failed" SDK call actually worked. Tell the user to check the transactions.

This is the band aid until odysee-api/401 is addressed.
2022-04-04 07:02:23 -04:00
infinite-persistence
491c934119 Fix makeSelectContentPositionForUri memo
- Move away from the leaky makeSelect* pattern.
- No memoization since it's pretty light.
2022-04-01 09:58:09 -04:00
infinite-persistence
fb998208e2 Add flow to Content slice 2022-04-01 09:58:09 -04:00
infinite-persistence
1a2fefa6ec Option to hide notification count in title bar 2022-03-31 10:23:31 -04:00
infinite-persistence
e9e232f008 Consolidate transaction result strings
## Issue
Accumulation of so many strings for a "successful tip" that it is getting annoying to re-translate them for minor changes.

## Change
- Consolidate and re-use strings.
- Make the tip string currency-agnostic so we don't have to touch it again. The amount and currency is moved to the `subMessage`.
- Fix spacing being incorrectly enforced through i18n (it should be done via code/css).
2022-03-30 21:59:54 -04:00
Anthony
911ccaa07e
Support EUR tipping #1222 2022-03-30 13:43:07 +08:00
Anthony
fe9b33e42b allow tips in euros 2022-03-29 23:00:55 -04:00
Anthony
631d3cc1f3 supporting EURO icon 2022-03-29 23:00:55 -04:00
infinite-persistence
9fe20699a0 doResolveUris, doResolveClaimIds: Return resolved empty results rather than undefined promise for the no-op case.
This allows clients to chain without needs to check if it's undefined.
2022-03-29 21:21:58 -04:00
infinite-persistence
122d561a20 Batch resolve with claim_search | [Recommended, Comments]
Ticket: 1189

## Issue
There is a bug in a batched `resolve` that returns jumbled data. Temporarily switch to `claim_search` until that is fixed.

## Notable differences:
- `resolve` will tell us directly that a claim has been removed or filtered, so redux will mark the ID as such. `claim_search` simply returns nothing, so we will still end up with an extra `resolve` for these items when the component tries to display it.

- The new function currently does not handle Collections (i.e. resolving individual items in the Collection) and Reposts. Given that this is temporarily, I'd like to leave `doClaimSearch` as is, instead of trying to replicate what's in `doResolveUris`.

## Notes:
Since we don't care if the resolve fails (and we weren't doing anything in the `catch` anyways), use `finally` instead.
2022-03-29 21:21:58 -04:00
Anthony
fed8fafe6c allow user to select preferred currency 2022-03-28 15:30:36 -04:00
David Granado
2c3432c9cb Guess at the correct value for 'PAGES.DOWNLOADED' 2022-03-26 00:54:39 -04:00
David Granado
3c20332912 Fix incorrect imports 2022-03-26 00:54:39 -04:00
infinite-persistence
173ab36451
Beautify FYP toast 2022-03-24 16:16:54 +08:00
infinite-persistence
f1ea0b20dd
Fix i18n issues reported
- Changed to "Add a Card" to reuse existing string.
2022-03-24 15:36:09 +08:00
infinite-persistence
42451e14a8
Split toast wrappers into separate file 2022-03-24 15:19:50 +08:00
infinite-persistence
e0ddd94c01
Rename: [commentron-error.js] -> [api-message.js] 2022-03-24 15:18:13 +08:00
infinite-persistence
f53680ea63
Refactor ERR_MAP to be general purpose
- Remove the need for an object key. Just use an array. It gets hard to maintain as more messages come in, and so far there is no need to access the configs directly.

- Just focus on handling the message and not creating a toast object. Leave the latter to the client.
2022-03-24 15:16:47 +08:00
infinite-persistence
a96db41782 FYP: show placeholder tiles when fetching membership or fyp itself.
This prevents the "no membership" and "no recommendations" message from flashing during load.
2022-03-23 23:21:46 -04:00
infinite-persistence
ec5cd10ab1 Remove hideFyp setting 2022-03-23 15:35:27 -04:00
infinite-persistence
5b16b3b058 Ability to customize homepage
Ticket: 1145

- Limited to premium for now (early access).
- Needed to handle custom categories from non-English homepages.
2022-03-23 15:35:27 -04:00
infinite-persistence
8fd64b2b41 TMP: switch fyp batch-resolve to claim_search
There is an intermittent bug with a batched `resolve`, where results are jumbled up. Switch to `claim_search` until that is resolved.
2022-03-23 09:23:02 -04:00
infinite-persistence
db38cc597f Quick membership override in debug mode 2022-03-23 09:23:02 -04:00
Rafael
dcb19a9f48 Improve wording for CA 2022-03-23 09:16:52 -04:00
Anthony
70b801e867 cleanup 2022-03-22 16:07:05 -04:00
Anthony
7508dc2970 use window instead of component state 2022-03-22 16:07:05 -04:00
Anthony
620e5023a8 add livestream icon and channel selector 2022-03-22 16:07:05 -04:00
saltrafael
05b228400e
Fix referrer on embed (#1181)
* Fix referrer on embed

* Fix override

* Fix condition
2022-03-22 14:13:19 -04:00
infinite-persistence
429653a7dc More sidebar optimizations
- Remove the odd resolve call that's lingering in `App`. Feels out of place, plus we don't need it now since the "active subs" claim search would contain resolved results.

- Don't search for active subs if Following count is zero.
2022-03-22 08:46:27 -04:00
infinite-persistence
56966ffa31 Fix sidebar active subs not batch-resolving
`Lbry.claim_search` was used, so it doesn't save the resolved results to redux. Use `doClaimSearch`.
2022-03-22 00:18:46 -07:00
Rafael
bc3c56b84b Locale Nag Fixes 2022-03-21 09:36:59 -04:00
infinite-persistence
5e2100000d Better handling of SDK errors
## Issue
- Errors like "unexpected token at..." and "failed to fetch" are being logged, rather than the actual call error.
- Publish SDK timeout is sometimes successful, but the user doesn't know, so they re-created the same claim

## Change
- Attempt to make the logs more helpful, and the error message more meaningful to the user.
- Starting off with 'publish' and tip SDK call as an experiment. Can add others if this method works.
2022-03-18 09:11:04 -04:00
infinite-persistence
35f0777320 FYP: fix "ignore" response handling (it's not a json) 2022-03-17 10:34:37 -04:00
infinite-persistence
a31ea6417a FYP: "Don't recommend channel" 2022-03-17 10:34:37 -04:00
infinite-persistence
51079ea611 Consolidate legal/requirements fetch
Ticket: 1128

Requirements:
- Fetch once per refresh. This is to cover the case of switching to VPNs, etc.
- 1 call per refreshed session.
2022-03-17 10:25:59 -04:00
infinite-persistence
f01004e9b6 FYP: setting to hide section 2022-03-17 10:11:50 -04:00
infinite-persistence
ec2bf26817
Fix flow for User/UserState 2022-03-17 13:12:18 +08:00
Rafael
f4fdee8331 socket improvements 2022-03-16 16:36:50 -04:00
Thomas Zarebczan
60c317dedf various fixes 2022-03-16 16:36:50 -04:00
Rafael
6ce9bd5cf7 Fixes 2022-03-16 16:36:50 -04:00
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