about summary refs log tree commit diff
path: root/src/state/queries/feed.ts
Commit message (Collapse)AuthorAgeFilesLines
* Enable show less / more buttons for third party feeds (#8672)kindgracekind2025-08-261-0/+31
| | | | | Co-authored-by: hailey <hailey@blueskyweb.xyz> Co-authored-by: Hailey <me@haileyok.com>
* [Explore] Reduced experience (#8160)Eric Bailey2025-04-081-11/+11
| | | | | | | | | | | * Only show suggested users for non-english users * Fall back to searching for users for non-english speakers * Disable other queries if full experience is disabled * Bump package * If no content langs, use full exp
* New reporting flow (#7832)Eric Bailey2025-02-281-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Add option to align web dialogs to top * Add new wait util * Pipe through feed view to feed components * Reset unneeded change to main * Copy over fresh report dialog based on old * Hack in temp testing data * Swap in new dialog in all cases but chat * Cleanup * Add load and initial error state * Fill in states * Add copyright link * Handle single labeler case * Comment out debug code * Improve centering of type in circles * Open details if Other is selected * Remove debug code * Tweak colors * Bump SDK * Tweak Admonition for better x-platform styles * Add retry button * Add close button * Remove todo not covered in this PR * Translate Retry
* Use effective filtering for feeds (#7736)Eric Bailey2025-02-131-2/+2
|
* yolo (#7499)Hailey2025-01-191-0/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * tweaks to constants (#7478) * add did * use correct did * typo * tweak * Prevent Drawer gesture conflicting with Suggestions scroll (#7468) * Extract BlockDrawerGeesture * Block drawer when scrolling interstitials (cherry picked from commit 9e3f2f43745eed9c71cb985e48135b7363d91aa9) * yolo interstitial * yolo mode * right swipe * fix nav gesture * vibe controls * collapsible post text * rm blurview, cover for tall videos * smarter video source handling * use thumbnails, improve perf significantly * better android loading * improve aspect ratio * optimize source changes * rm spinner on ios * whoops, remove debug `false` * FIX WRONG VIDEOS SHOWING UP * don't spring on way down * release video players when leaving screen * remove jank animation * Add grid * improve contract, fix double tap * Filter out posts without videos * Only do grid on native * Pipe through feedSourceUri and link to feed * Handle passed through params * Partial revert, just filter posts to start at index * Clean up cards, remove entry interstitial * Tweak handle * Change constant name * Rename some things * Make types legit * Clean up more naming * Add placeholder for grid view * Handle web, set up new organization * Begin work on Header * Replace types * Squashed commit of the following: commit 3d1be4c0f19789dd3c5a3572ec1acd744a2edb80 Author: Samuel Newman <mozzius@protonmail.com> Date: Fri Jan 17 01:08:05 2025 +0000 extend animation commit c9f199413b018efcbd9d8d2a58dd05eb41e7acb7 Author: Samuel Newman <mozzius@protonmail.com> Date: Fri Jan 17 01:01:24 2025 +0000 fix gap commit 22e520795f50efda176f21a5e967cb27d0cdd907 Author: Samuel Newman <mozzius@protonmail.com> Date: Fri Jan 17 00:50:16 2025 +0000 thinner bar, format time commit c32427f21405294ed3567545629a2964c4af59fe Author: Samuel Newman <mozzius@protonmail.com> Date: Fri Jan 17 00:47:57 2025 +0000 fix 2 in 3 screens commit cbf84c08d64ca0a08ba9070ef5db918f89aa4296 Author: Samuel Newman <mozzius@protonmail.com> Date: Fri Jan 17 00:45:46 2025 +0000 rm unneeded var commit 7e0e100177bb1cd0e64c0841bb7685c7f1eb857f Author: Samuel Newman <mozzius@protonmail.com> Date: Fri Jan 17 00:41:18 2025 +0000 scrubberrrrr * use white with opacity rather than gray * Simultaneous gesture * cleanup attempt * fix jank * link to profile on press * fix jitter fr this time * mostly fix android flicker * Maybe fix row generation * Add content hider to video card * emoji in post text * reduce update rate * fix type error * Fix grid layout trailing single item * Add Discover interstitial, settings, includes pin for now * Explore interstitial, handle dimissal, pinning, compact card * Only use grid placeholder on native * Update events * Add feature gate * android nav bar fixes + lower update speed * fix interval + decel rate on interstitials * attempt to fix broken scrub on android (not working) * follow button * Part out the interstitials for perf, add view more * Remove prod web route * Wrap interstitials with BlockDrawerGesture * Bring video cropping in line with images (#7462) * Mimic image cropping for videos on web * Same on native * Rename variables for clarity * Fix Android scrubbing * Add FeedFeedbackProvider * Remove swipe gesture * fix light status bar behaviour * bump * feedback * Copy pasta to new location * Copy pasta part deux * Filter only videos * Make whole text clickable to expand (cherry picked from commit 4cf31120779f4e06eb4c296b3d4b53814d432b07) * move scrubber to own file * end card * add icon to end card * add min view time to viewability config * play haptic on like * tweak feedback * tweak feedback again * Moderation (cherry picked from commit 6b6b471cfb363031284b3e7a1f6e0ade3ac4ae47) * remove bad check * fix feedback for new video grid * change prop name to items as well * Simplify logic * Fix mod footer * Give scrubber more space on android * Add subtle track behind scrubber, adjust opacity * wire in feed context again... * Add better a11y desc to card * Fix key issue * Update a11y copy * Fix scrubber height * improve scrubber animation * Make follow button more obvious * Make header back button more clear * Disable interactions with actual video el * keep content away from the bottom safe area * fix blur * fix moderation issue * improve contrast on mod screen * Make moderation static per item * Memoize rows * Optimizations * Take video moderation into account * Only blur titles for list blur * Change copy * Bump blur radius * animate text in both directions * Rm unused field * Filter by root early * Refactor for clarity * add compose prompt to scrubber * rm log * tweak gradient * Bump SDK, use contentMode to power video feed * Ensure ProfileFeed view also supports video feed * improve scrubber on android * rm border from footer * Update prod video feed did * Separate caches * Add lil hover to View More * Fix undefined logic, remove header for interstitial * Ungate * Fix stuckness * remove extra useless map * Fix effect cleanup * Send seen without cleanup * Simplify react stuff * Earlier early return to avoid loading flash * remove scrubber placeholder * Remove opacity hack * Render useEvent conditionally * Fix Android flash --------- Co-authored-by: dan <dan.abramov@gmail.com> Co-authored-by: Samuel Newman <mozzius@protonmail.com> Co-authored-by: Eric Bailey <git@esb.lol>
* Don't kick to login screen on network error (#4911)dan2024-08-131-1/+2
| | | | | | | | | | | | | | | | | | | | | * Don't kick the user on network errors * Track online status for RQ * Use health endpoint * Update test with new behavior * Only poll while offline * Handle races between the check and network events * Reduce the poll kickoff interval * Don't cache partially fetched pinned feeds This isn't a new issue but it's more prominent with the offline handling. We're currently silently caching pinned infos that failed to fetch. This avoids showing a big spinner on failure but it also kills all feeds which is very confusing. If the request to get feed gens fails, let's fail the whole query. Then it can be retried.
* Respect labels on feeds and lists (#4818)Eric Bailey2024-08-021-20/+33
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Prep * Pass in optional moderation to FeedCard * Compute moderation decision, filter contentList contexts, pass into card * Let's go a different route * Filter from within search queries * Use same search query for starter packs * Filter lists from profile tabs * Cleanup * Filter from profile feeds * Moderate post embeds * Memoize * Use ScreenHider on lists * Hide both list types * Fix crash on iOS in screen hider, fix lineheight * Memoize renderItem * Reuse objects to prevent re-renders
* Fix crash in Feeds and Starter Packs (#4616)dan2024-06-241-16/+28
| | | | | | | * Remove useless check * Fix the bug by only adding resolved feeds/lists * Clarify the purpose of the count field
* Starter Packs (#4332)Hailey2024-06-211-0/+17
| | | | | | | Co-authored-by: Dan Abramov <dan.abramov@gmail.com> Co-authored-by: Paul Frazee <pfrazee@gmail.com> Co-authored-by: Eric Bailey <git@esb.lol> Co-authored-by: Samuel Newman <mozzius@protonmail.com>
* Tweak feed card to prevent spinnerz when pushing to screen (#4600)Hailey2024-06-211-1/+9
|
* Pinned feeds cards (#4526)Eric Bailey2024-06-221-0/+139
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Add lists support to FeedCard * Add useSavedFeeds query, similar to usePinnedFeedInfos * Integrate into Feeds screen * Fix alignment on mobile * Update usages * Add placeholder loading state * Handle no feeds state * Reuse previous data for placeholder * Staged loading * Improve staged loading * Use setQueryData approach to pre-caching * Add types for a little more safety * Fix precaching --------- Co-authored-by: Dan Abramov <dan.abramov@gmail.com>
* Select, don't mutate (#4541)Eric Bailey2024-06-171-19/+21
|
* Redo explore page (#4491)Eric Bailey2024-06-141-2/+32
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Redo explore page, wip * Remove circle icons * Load more styling * Lower limit * Some styling tweaks * Abstract * Add tab, query, factor out * Revert unneeded change * Revert unneeded change v2 * Update copy * Load more styling * Header styles * The thin blue line * Make sure it's hairline * Update query keys * Border * Expand avis * Very load more copy
* Reuse overfetching for popular feeds, add in existing filtering (#4501)Eric Bailey2024-06-141-5/+95
|
* Replace getAgent() with reading agent (#4243)dan2024-05-281-12/+12
| | | | | * Replace getAgent() with agent * Replace {agent} with agent
* Movable following feed (#3593)Eric Bailey2024-05-111-37/+64
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Handle home algo with backwards compat * Remove todo, fix pwi view * Simplify filter logic * Handle edge case * Handle home algo in FeedSourceCard * Fix handling of pinned feed if home algo is disabled * Handle home algo on ProfileFeed screen * Rename * Fix pinned feeds key * Improve perf of pinned feeds with primary algo * Update statsig API * Revert unneeded changes * Support following feed as well * Better formatting * Clarify primary algo usage * Better comment * Handle saved feed screen edge case * Restore Feeds sparkle, fix line height * Move gate call down * Filter out primary algo from feeds page * Filter dupe from Feeds screen * Simplify logic * Missing following handling * Hide primary feed setting outside exp * Revert testing change * Migrate usePinnedFeedInfos * Migrate FeedSourceCard * Migrate Feeds screen * Migrate SavedFeeds screen * Handle timeline in feed infos * Finish migrating ProfileFeed, FeedSourceCard * Migrate ProfileList * Finalize mutation hooks * Allow unsaving lists * Handle following feed on Feeds screen * Handle following on SavedFeeds * Get rid of deprecated interface usages * Handle no pinned feeds * Handle no feeds on Feeds screen * Reuse component on SavedFeeds screen * Handle no following feed * Remove primary algo references * Migrate to new plural APIs * Remove unused event * Prevent duplicate keys * Make handling much more clear * Dedupe useHeaderOffset * Filter unknown feed types at source * Use just following * Immprove key handling * Resume from last tab * Bump sdk * Revert Gemfile * Additional protection in FeedSourceCard * Fix ProfileList save/unsave handling * Translate * Translate * Match existing handling post-signup * Ensure onboarding results in correct selected feeds * Some testing tweaks on create/onboarding * Revert primary algo consderations * Remove comment * Handle default feed setting * Rm unnecessary type cast * Remove premature gate check * Remove nullable check in onPageSelecting, assume the pager checks bounds * Use null for default selected feed * Rm unrelated change * Remove the concept of __key__ I don't think this concept is consistent. It's introduced on FeedSourceInfo which is used both by pinned feeds and by useFeedSourceInfoQuery. Pinned feeds use the pinning ID there. But there is no pinning ID for useFeedSourceInfoQuery. So this means this field is sometimes one thing and sometimes some other thing. That is a decent sign that it shouldn't be on that type at all. It's not used anywhere except the desktop feed enumeration. It seems reasonable to assume there that we wouldn't want to show the same feed URL twice. (And if it does occur in the array twice, IMO we should solve that at the API level and dedupe it on read or next write.) So I think we should just use the URL in that place. (I used the descriptor, which is equivalent.) * Dedupe pinned feeds by URL on read * Filter timeline out of mergefeed sources * Put FeedDescriptor into FeedSourceInfo * Group saved info with feed for pins This removes a loop within a loop within a loop. * Fix Feeds link on native --------- Co-authored-by: Dan Abramov <dan.abramov@gmail.com>
* [Session] Add `useAgent` hook and replace (#3706)Eric Bailey2024-04-251-1/+5
| | | | | | | | | | | * Hook it up * Memoize getAgent method * Use one shared reference --------- Co-authored-by: Dan Abramov <dan.abramov@gmail.com>
* PWI improvements (#3489)Paul Frazee2024-04-121-3/+24
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Enable home and feeds on the PWI * Add global SigninDialog to drive useRequireAuth() * Tweak desktop styles * Make the logo in leftnav PWI a clickable home link * Add label * Improve dialog on web * Fix query key * Go to home after signout from settings screen * Filter out feeds from the discover listing for logged out users which are known to break without auth * Update profile header follow/subscribe to give signin prompt * Show profile feeds tabs on pwi * Add language selector to account creation footer and pwi left nav desktop --------- Co-authored-by: dan <dan.abramov@gmail.com>
* Extract query key roots to constants (#3404)dan2024-04-041-14/+17
| | | | | | | * Extract query key roots to constants * Dedupe labelers-detailed-info * Align naming
* Fix wrong feed being shown (#3015)dan2024-02-281-78/+51
|
* Avatar type for Feed check (#2661)Prates2024-01-301-0/+4
| | | | | * Changed type from algo to list * Fixed to check if it's a feed or a list
* Reduce some Sentry logs (#2549)Eric Bailey2024-01-161-1/+2
| | | | | * Reduce some Sentry logs * Update tests
* Fix blank home screen (close #2281) (#2291)Paul Frazee2023-12-241-1/+4
|
* Use same source for pinned feeds on Home and tab/sidebars (#2235)Eric Bailey2023-12-181-0/+1
|
* Traffic reduction and tuned caching strats (#2215)Paul Frazee2023-12-151-45/+0
| | | | | | | | | | | | | * Update the feed to only check latest on focus after 30s, but to do a full reset on focus after 1 hour to avoid very stale data * Remove the isFeedPublic query * Fix: avoid double next-page fetches * Reduce some poll intervals to reduce server load * Guard against double-fires of fetchNextPage * Reduce polling on blurred screens
* Handle failed pinned feed fetches when rendering list of pinned feeds (#2173)Eric Bailey2023-12-111-20/+33
|
* Surface raw server error if exists (#2096)Eric Bailey2023-12-051-3/+15
| | | | | | | | | | | * Surface raw server error if exists * Update copy * Update translation files --------- Co-authored-by: Paul Frazee <pfrazee@gmail.com>
* Better handle feed auth failures (#2060)Eric Bailey2023-12-011-6/+7
| | | | | * Better handle feed auth failures * Add comment
* Slightly less verbose variablePaul Frazee2023-11-291-3/+3
|
* Add hasPinnedCustomFeedOrList to usePinnedFeedsInfos hookCooper Edmunds2023-11-291-2/+9
|
* Fix pinned feeds mutation issue (#2016)Eric Bailey2023-11-281-8/+1
|
* Handle other feed auth response (#2012)Eric Bailey2023-11-281-0/+3
|
* Fall back for non-public feeds (#1988)Eric Bailey2023-11-241-0/+29
|
* Move the current agent to a global and reset RQ queries on agent change (#1946)Paul Frazee2023-11-161-14/+7
|
* Caching heuristics (#1938)Eric Bailey2023-11-161-0/+2
| | | | | * Tempfix profile load * First pass at staleTime
* Factor our feed source model (#1887)Eric Bailey2023-11-131-33/+35
| | | | | | | | | | | | | | | | | | | | | * Refactor first onboarding step * Replace old FeedSourceCard * Clean up CustomFeedEmbed * Remove discover feeds model * Refactor ProfileFeed screen * Remove useCustomFeed * Delete some unused models * Rip out more prefs * Factor out treeView from thread comp * Improve last commit
* More prefs cleanup (#1882)Eric Bailey2023-11-131-11/+121
| | | | | | | | | | | * Update useHomeTabs * Use queryClient to fetch * Replace useHomeTabs and useDesktopRightNavItems * Fix type error * Some cleanup
* Refactor My Feeds (#1877)Eric Bailey2023-11-121-2/+68
| | | | | | | * Refactor My Feeds screen * Remove unused feed UI models * Add back PTR
* Eric/preferences (#1873)Eric Bailey2023-11-121-0/+106
* Add initial preferences query, couple mutations * Remove unused * Clean up labels, migrate getModerationOpts * Add birth date handling * Migrate feed prefs * Migrate thread view prefs * Migrate homeFeed to use existing key name * Fix up saved feeds in response, no impl yet * Migrate saved feeds to new hooks * Clean up more of preferences * Fix PreferencesThreads load state * Fix modal dismissal * Small spacing fix --------- Co-authored-by: Paul Frazee <pfrazee@gmail.com>