Skip to content

Conversation

@dariakoko
Copy link
Contributor

@dariakoko dariakoko commented Jan 9, 2026

This PR resolves ONYX-1956

Description

Updated the header of the auction results screens to use Palette's Screen.AnimatedHeader and Screen.StickySubHeader.
To enable Screen.AnimatedHeader and Screen.StickySubHeader, I replaced the Animated.SectionList component with Screen.FlatList. This required additional adjustments to preserve the existing sticky auction-date component behavior.

Before After iOS After Android
Simulator.Screen.Recording.-.iPhone.13.mini.-.2026-01-16.at.16.20.13.mp4
auctions.screens.header.webm

PR Checklist

  • I have tested my changes on the following platforms:
    • Android.
    • iOS.
  • I hid my changes behind a feature flag, or they don't need one.
  • I have included screenshots or videos at least on Android, or I have not changed the UI.
  • I have added tests, or my changes don't require any.
  • I added an app state migration, or my changes do not require one.
  • I have documented any follow-up work that this PR will require, or it does not require any.
  • I have added a changelog entry below, or my changes do not require one.

To the reviewers 👀

  • I would like at least one of the reviewers to run this PR on the simulator or device.
Changelog updates

Changelog updates

Cross-platform user-facing changes

  • updated Auctions screen header to use Screen.AnimatedHeader and Screen.StickySubHeader

iOS user-facing changes

Android user-facing changes

Dev changes

  • edit title of the latest auction results screen to use Palette AnimatedHeader

Need help with something? Have a look at our docs, or get in touch with us.

Copy link
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

This PR refactors auction results screens to use Palette's AnimatedHeader component instead of a custom floating header implementation. The change converts a SectionList-based implementation to a FlatList-based one with manual sticky header management.

Changes:

  • Replaced custom floating header with Screen.AnimatedHeader and Screen.StickySubHeader components
  • Converted SectionList to FlatList with custom viewability tracking for sticky section headers
  • Removed ListHeaderComponent prop and floatingHeaderTitle prop from AuctionResultsList

Reviewed changes

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

File Description
AuctionResultsForArtistsYouCollect.tsx Updated to use Screen.AnimatedHeader and Screen.Body wrapper components
AuctionResultsScreenWrapper.tsx Updated to use Screen.AnimatedHeader and Screen.Body wrapper components, removed ListHeader usage
AuctionResultsList.tsx Major refactoring from SectionList to FlatList with custom sticky header logic and viewability tracking

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment on lines +137 to +139
if (index === 0 && item.type === "section-header") {
// Skip rendering the first section header since it's sticky
return null
Copy link

Copilot AI Jan 13, 2026

Choose a reason for hiding this comment

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

Skipping the first section header (index === 0) assumes that the first item is always a section header. If the auctionResults array is empty or in an unexpected state, this could cause issues. Consider checking if the item type is 'section-header' rather than just checking the index.

Copilot uses AI. Check for mistakes.
Copy link
Contributor Author

Choose a reason for hiding this comment

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

This is correct - given the current flatListData builder, for a non-empty auctionResults the code always pushes a section header before the group's items, so the first element will be a "section-header"

@dariakoko dariakoko marked this pull request as ready for review January 16, 2026 17:01
@ArtsyOpenSource
Copy link
Contributor

This PR contains the following changes:

  • Cross-platform user-facing changes (updated Auctions screen header to use Screen.AnimatedHeader and Screen.StickySubHeader - dariakoko)
  • Dev changes (edit title of the latest auction results screen to use Palette AnimatedHeader - dariakoko)

Generated by 🚫 dangerJS against c9da069

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants