Skip to content

refactor: improve async content (@miodec)#7899

Merged
Miodec merged 16 commits intomasterfrom
async
May 3, 2026
Merged

refactor: improve async content (@miodec)#7899
Miodec merged 16 commits intomasterfrom
async

Conversation

@Miodec
Copy link
Copy Markdown
Member

@Miodec Miodec commented May 2, 2026

No description provided.

Copilot AI review requested due to automatic review settings May 2, 2026 18:32
@monkeytypegeorge monkeytypegeorge added the frontend User interface or web stuff label May 2, 2026
@github-actions github-actions Bot added the waiting for review Pull requests that require a review before continuing label May 2, 2026
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Refactors AsyncContent to expose query results as Solid accessors instead of raw values, then updates frontend call sites, stories, and tests to use the new reactive API. This fits the frontend’s SolidJS migration by making async content consumption more signal-friendly.

Changes:

  • Change AsyncContent child props to pass accessors and add logic to retain the last resolved value during deferred loading.
  • Update frontend consumers (AboutPage, LeaderboardPage, ProfilePage, Inbox, VersionHistoryModal) and Storybook stories to call returned accessors.
  • Adjust AsyncContent tests to match the new accessor-based API for single and multi-query cases.

Reviewed changes

Copilot reviewed 8 out of 8 changed files in this pull request and generated 2 comments.

Show a summary per file
File Description
frontend/storybook/stories/AsyncContent.stories.tsx Updates Storybook examples to read async values via accessors.
frontend/src/ts/components/popups/alerts/Inbox.tsx Adapts inbox list rendering to the new AsyncContent child API.
frontend/src/ts/components/pages/profile/ProfilePage.tsx Updates profile rendering to unwrap the async profile accessor.
frontend/src/ts/components/pages/leaderboard/LeaderboardPage.tsx Refactors leaderboard consumers to read accessor-backed async query results.
frontend/src/ts/components/pages/AboutPage.tsx Updates stats, charts, supporters, and contributors sections to use accessors.
frontend/src/ts/components/modals/VersionHistoryModal.tsx Adjusts version history rendering for accessor-based infinite-query data.
frontend/src/ts/components/common/AsyncContent.tsx Core refactor: accessor-based children plus cached last resolved value and loader behavior changes.
frontend/__tests__/components/common/AsyncContent.spec.tsx Rewrites tests around the new accessor contract for AsyncContent.

Comment thread frontend/src/ts/components/common/AsyncContent.tsx
Comment thread frontend/src/ts/components/common/AsyncContent.tsx
Comment thread frontend/src/ts/components/pages/leaderboard/LeaderboardPage.tsx Outdated
@github-actions github-actions Bot removed the waiting for review Pull requests that require a review before continuing label May 2, 2026
Comment thread frontend/src/ts/components/pages/leaderboard/LeaderboardPage.tsx
@Miodec Miodec merged commit a1efc6d into master May 3, 2026
15 checks passed
@Miodec Miodec deleted the async branch May 3, 2026 08:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

frontend User interface or web stuff

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants