Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: button reveal animation (DSN-2529) #315

Closed
wants to merge 3 commits into from

Conversation

mikaalnaik
Copy link
Contributor

Fixes or implements VF-XXX

Brief description. What is this change?

Implementation details. How do you make this change?

Setup information

Deployment Notes

Related PRs

Checklist

  • Breaking changes have been communicated, including:
    • New required environment variables
    • Renaming of interfaces (API routes, request/response interface, etc)
  • New environment variables have been deployed
  • Appropriate tests have been written
    • Bug fixes are accompanied by an updated or new test
    • New features are accompanied by a new test

@mikaalnaik mikaalnaik self-assigned this Nov 15, 2024
Copy link

linear bot commented Nov 15, 2024

Copy link

vercel bot commented Nov 15, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
react-chat ✅ Ready (Inspect) Visit Preview 💬 Add feedback Nov 15, 2024 5:41pm

Copy link

graphite-app bot commented Nov 15, 2024

Your org requires the Graphite merge queue for merging into master

Add the label “merge” to the PR and Graphite will automatically add it to the merge queue when it’s ready to merge. Or use the label “hotfix” to add to the merge queue as a hot fix.

You must have a Graphite account and log in to Graphite in order to use the merge queue. Sign up using this link.

Comment on lines 116 to 140
<div
className={buttonAnimation}
style={{
animationDelay: `${index * 0.1}s`,
}}
>
<Button variant={ButtonVariant.INLINE} onClick={() => runtime?.interact(request, name)} key={index}>
{name}
</Button>
</div>
Copy link

Choose a reason for hiding this comment

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

The React key prop needs to be moved from the Button to the wrapping div element to ensure proper list reconciliation. Currently:

<div className={buttonAnimation}>
  <Button key={index} ...>

Should be:

<div key={index} className={buttonAnimation}>
  <Button ...>

This change will help React correctly track and update the animated button elements in the list.

Spotted by Graphite Reviewer

Is this helpful? React 👍 or 👎 to let us know.

Copy link

sonarcloud bot commented Nov 15, 2024

Copy link

graphite-app bot commented Nov 15, 2024

Merge activity

  • Nov 15, 1:11 PM EST: A user added this pull request to the Graphite merge queue.
  • Nov 15, 1:12 PM EST: CI is running for this PR on a draft PR: #319
  • Nov 15, 1:19 PM EST: A user merged this pull request with the Graphite merge queue via draft PR: #319.

mikaalnaik added a commit that referenced this pull request Nov 15, 2024
<!-- You can erase any parts of this template not applicable to your Pull Request. -->

**Fixes or implements VF-XXX**

### Brief description. What is this change?

<!-- Build up some context for your teammates on the changes made here and potential tradeoffs made and/or highlight any topics for discussion -->

### Implementation details. How do you make this change?

<!-- Explain the way/approach you follow to make this change more deeply in order to help your teammates to understand much easier this change -->

### Setup information

<!-- Notes regarding local environment. These should note any new configurations, new environment variables, etc. -->

### Deployment Notes

<!-- Notes regarding deployment the contained body of work. These should note any db migrations, etc. -->

### Related PRs

<!-- List related PRs against other branches -->

- https://github.com/voiceflow/XXXXXXXXX/pull/123

### Checklist

- [ ] Breaking changes have been communicated, including:
    - New required environment variables
    - Renaming of interfaces (API routes, request/response interface, etc)
- [ ] New environment variables have [been deployed](https://www.notion.so/voiceflow/Add-Environment-Variables-be1b0136479f45f1adece7995a7adbfb)
- [ ] Appropriate tests have been written
    - Bug fixes are accompanied by an updated or new test
    - New features are accompanied by a new test
@graphite-app graphite-app bot closed this Nov 15, 2024
@graphite-app graphite-app bot deleted the mikaal/button-animation/DSN-2529 branch November 15, 2024 18:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants