feat: implement issues #1113-#1116 — LoadingSkeleton variants, useMarkets, useMarket, useMarketBets - #1155
Merged
Ehonrie merged 2 commits intoJul 27, 2026
Conversation
…variants, useMarkets, useMarket, useMarketBets Netwalls#1113 — LoadingSkeleton: add card/row/detail variants that mirror the exact dimensions of MarketCard, PortfolioTable rows, and MarketDetailClient layout, preventing layout shift. Legacy table/chart variants retained for back-compat. Netwalls#1114 — useMarkets: expose configurable pollingInterval option (default 30 s), pause polling when the browser tab is backgrounded (document.visibilityState), keep isLoading/error/refetch surface unchanged. Netwalls#1115 — useMarket: guarantee market field is null while loading and on any error (including 404), reset to null immediately on market_id change so consumers never render stale data. Netwalls#1116 — useMarketBets: new hook that fetches bets for a market and sorts them most-recent-first by placedAt before returning. Includes test suite and shared mockFetchMarketBets / OLDER_BET fixture in mockApiClient.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
#1113 — LoadingSkeleton: add card/row/detail variants that mirror the exact dimensions of MarketCard, PortfolioTable rows, and MarketDetailClient layout, preventing layout shift. Legacy table/chart variants retained for back-compat.
#1114 — useMarkets: expose configurable pollingInterval option (default 30 s), pause polling when the browser tab is backgrounded (document.visibilityState), keep isLoading/error/refetch surface unchanged.
#1115 — useMarket: guarantee market field is null while loading and on any error (including 404), reset to null immediately on market_id change so consumers never render stale data.
#1116 — useMarketBets: new hook that fetches bets for a market and sorts them most-recent-first by placedAt before returning. Includes test suite and shared mockFetchMarketBets / OLDER_BET fixture in mockApiClient.
Closes #1113
Closes #1114
Closes #1115
Closes #1116