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

chore: Widgetize flashbar #3334

Draft
wants to merge 1 commit into
base: main
Choose a base branch
from
Draft

chore: Widgetize flashbar #3334

wants to merge 1 commit into from

Conversation

just-boris
Copy link
Member

Description

Make flashbar component to load via widget

Related links, issue #, if available: n/a

How has this been tested?

Tests in my dev pipelines

Review checklist

The following items are to be evaluated by the author(s) and the reviewer(s).

Correctness

  • Changes include appropriate documentation updates.
  • Changes are backward-compatible if not indicated, see CONTRIBUTING.md.
  • Changes do not include unsupported browser features, see CONTRIBUTING.md.
  • Changes were manually tested for accessibility, see accessibility guidelines.

Security

Testing

  • Changes are covered with new/existing unit tests?
  • Changes are covered with new/existing integration tests?

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

const isReducedMotion = useReducedMotion(ref);
const isVisualRefresh = useVisualRefresh();
Copy link
Member Author

Choose a reason for hiding this comment

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

Moved isVisualRefresh from the hook directly into component code to make DCE work for ALWAYS_VISUAL_REFRESH mode

Comment on lines -28 to -30
const { __internalRootRef } = useBaseComponent('Flashbar', {
props: { stackItems: restProps.stackItems },
});
Copy link
Member Author

Choose a reason for hiding this comment

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

Moved it into the flashbar/index.tsx file to make this hook run before the widget loaded

Copy link

codecov bot commented Mar 6, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 96.42%. Comparing base (8ec9c2d) to head (45bc6af).

Additional details and impacted files
@@           Coverage Diff            @@
##             main    #3334    +/-   ##
========================================
  Coverage   96.42%   96.42%            
========================================
  Files         791      793     +2     
  Lines       22611    22618     +7     
  Branches     7396     7814   +418     
========================================
+ Hits        21803    21810     +7     
+ Misses        801      754    -47     
- Partials        7       54    +47     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

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.

1 participant