Skip to content

Comments

feat: chart transitions#400

Open
hcopp wants to merge 48 commits intomasterfrom
hunter/chart-transitions
Open

feat: chart transitions#400
hcopp wants to merge 48 commits intomasterfrom
hunter/chart-transitions

Conversation

@hcopp
Copy link
Contributor

@hcopp hcopp commented Feb 17, 2026

What changed? Why?

This PR adds support for chart transitions being customized separately for enter vs update.

UI changes

Coming Wednesday

iOS Old iOS New
old screenshot new screenshot
Android Old Android New
old screenshot new screenshot
Web Old Web New
old screenshot new screenshot

Testing

Test out new Transitions storybook on mobile and LineChart/AreaChart/BarChart transitions

How has it been tested?

  • Unit tests
  • Interaction tests
  • Pseudo State tests
  • Manual - Web
  • Manual - Android (Emulator / Device)
  • Manual - iOS (Emulator / Device)

Testing instructions

Illustrations/Icons Checklist

Required if this PR changes files under packages/illustrations/** or packages/icons/**

  • verified visreg changes with Terran (include link to visreg run/approval)
  • all illustration/icons names have been reviewed by Dom and/or Terran

Change management

type=routine
risk=low
impact=sev5

automerge=false

@cb-heimdall
Copy link
Collaborator

cb-heimdall commented Feb 17, 2026

🟡 Heimdall Review Status

Requirement Status More Info
Reviews 🟡 0/1
Denominator calculation
Show calculation
1 if user is bot 0
1 if user is external 0
2 if repo is sensitive 0
From .codeflow.yml 1
Additional review requirements
Show calculation
Max 0
0
From CODEOWNERS 1
Global minimum 0
Max 1
1
1 if commit is unverified 0
Sum 1
CODEOWNERS 🟡 See below

🟡 CODEOWNERS

Code Owner Status Calculation
ui-systems-eng-team 🟡 0/1
Denominator calculation
Additional CODEOWNERS Requirement
Show calculation
Sum 0
0
From CODEOWNERS 1
Sum 1

transition={transition}
transition={transitions?.update ?? transition}
yAxisId={yAxisId}
/>
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Gradient is just a mask of sorts over the path so it has no enter animation, just follows the enter animation of the path.

@hcopp hcopp changed the title Hunter/chart transitions feat: chart transitions Feb 18, 2026
@hcopp hcopp self-assigned this Feb 18, 2026
@hcopp hcopp requested a review from haoruikun-cb February 18, 2026 01:48
@hcopp hcopp marked this pull request as ready for review February 18, 2026 01:48
? (groupEnterTransition as { duration?: number }).duration
: accessoryFadeTransitionDuration;
return { duration: duration ?? accessoryFadeTransitionDuration };
}, [groupEnterTransition]);
Copy link
Contributor Author

Choose a reason for hiding this comment

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

todo: look into this further

// Track the previous idle state to detect idle<->scrubbing transitions.
const prevIsIdleRef = useRef(isIdle);
const isIdleTransition = isIdle !== prevIsIdleRef.current;
prevIsIdleRef.current = isIdle;
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Brought over from DefaultScrubberBeacon

width,
height,
borderRadius,
borderRadius = 4,
Copy link
Contributor Author

Choose a reason for hiding this comment

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

We already have this set in Bar.tsx but we set here as well for web so wanted to make it consistent.

i0Shared.value = i0;
i1Shared.value = i1;
toSkiaPathShared.value = toSkiaPath;
}, [i0, i1, toSkiaPath, i0Shared, i1Shared, toSkiaPathShared]);
Copy link
Contributor Author

Choose a reason for hiding this comment

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

I want to dig into this more on Monday, see if there is a better way to do this.

This allows us to interrupt an in progress animation, and makes things much smoother for charts with lots of changes.

@hcopp hcopp deployed to production February 20, 2026 21:27 — with GitHub Actions Active
> & {
transitions?: { enter?: Transition; update?: Transition };
}
>(
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 an internal only component, we are remaking transitions since at this spot we have already converted null instances into instantTransition (a valid transition) so now we should only have undefined or defined transition.

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

Development

Successfully merging this pull request may close these issues.

2 participants