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

Addon Test: Context menu UI #29727

Merged
merged 16 commits into from
Dec 2, 2024
Merged

Addon Test: Context menu UI #29727

merged 16 commits into from
Dec 2, 2024

Conversation

ghengeveld
Copy link
Member

@ghengeveld ghengeveld commented Nov 27, 2024

Fixes #29647

What I did

Updates the context menu for addon-test to provide info about each test type and allow changing settings.

Checklist for Contributors

Testing

The changes in this PR are covered in the following automated tests:

  • stories
  • unit tests
  • integration tests
  • end-to-end tests

Manual testing

This section is mandatory for all contributions. If you believe no manual test is necessary, please state so explicitly. Thanks!

Documentation

  • Add or update documentation reflecting your changes
  • If you are deprecating/removing a feature, make sure to update
    MIGRATION.MD

Checklist for Maintainers

  • When this PR is ready for testing, make sure to add ci:normal, ci:merged or ci:daily GH label to it to run a specific set of sandboxes. The particular set of sandboxes can be found in code/lib/cli-storybook/src/sandbox-templates.ts

  • Make sure this PR contains one of the labels below:

    Available labels
    • bug: Internal changes that fixes incorrect behavior.
    • maintenance: User-facing maintenance tasks.
    • dependencies: Upgrading (sometimes downgrading) dependencies.
    • build: Internal-facing build tooling & test updates. Will not show up in release changelog.
    • cleanup: Minor cleanup style change. Will not show up in release changelog.
    • documentation: Documentation only changes. Will not show up in release changelog.
    • feature request: Introducing a new feature.
    • BREAKING CHANGE: Changes that break compatibility in some way with current major version.
    • other: Changes that don't fit in the above categories.

🦋 Canary release

This PR does not have a canary release associated. You can request a canary release of this pull request by mentioning the @storybookjs/core team here.

core team members can create a canary release here or locally with gh workflow run --repo storybookjs/storybook canary-release-pr.yml --field pr=<PR_NUMBER>

name before after diff z %
createSize 0 B 0 B 0 B - -
generateSize 77.7 MB 77.7 MB 0 B 1.17 0%
initSize 130 MB 130 MB 168 B -0.73 0%
diffSize 52.4 MB 52.4 MB 168 B -0.73 0%
buildSize 6.83 MB 6.83 MB 11 B 0.96 0%
buildSbAddonsSize 1.51 MB 1.51 MB 0 B -0.69 0%
buildSbCommonSize 195 kB 195 kB 0 B - 0%
buildSbManagerSize 1.86 MB 1.86 MB 11 B 1.24 0%
buildSbPreviewSize 271 kB 271 kB 0 B -0.82 0%
buildStaticSize 0 B 0 B 0 B - -
buildPrebuildSize 3.84 MB 3.84 MB 11 B 1.25 0%
buildPreviewSize 3 MB 3 MB 0 B 0.73 0%
testBuildSize 0 B 0 B 0 B - -
testBuildSbAddonsSize 0 B 0 B 0 B - -
testBuildSbCommonSize 0 B 0 B 0 B - -
testBuildSbManagerSize 0 B 0 B 0 B - -
testBuildSbPreviewSize 0 B 0 B 0 B - -
testBuildStaticSize 0 B 0 B 0 B - -
testBuildPrebuildSize 0 B 0 B 0 B - -
testBuildPreviewSize 0 B 0 B 0 B - -
name before after diff z %
createTime 26.1s 7s -19s -85ms -1.14 -270.1%
generateTime 20.3s 22.1s 1.8s 0.01 8.3%
initTime 13.2s 14.1s 908ms -0.42 6.4%
buildTime 8.3s 9.4s 1s 0.39 10.9%
testBuildTime 0ms 0ms 0ms - -
devPreviewResponsive 5s 5.5s 502ms 0.61 9.1%
devManagerResponsive 3.7s 4s 298ms 1.77 🔺7.4%
devManagerHeaderVisible 628ms 918ms 290ms 4.96 🔺31.6%
devManagerIndexVisible 715ms 1s 300ms 5.95 🔺29.6%
devStoryVisibleUncached 1.7s 1.6s -21ms 0.5 -1.2%
devStoryVisible 713ms 1s 300ms 5.12 🔺29.6%
devAutodocsVisible 688ms 719ms 31ms 3.61 4.3%
devMDXVisible 641ms 605ms -36ms 1.29 🔰-6%
buildManagerHeaderVisible 634ms 1.1s 521ms 7.96 🔺45.1%
buildManagerIndexVisible 658ms 1.1s 512ms 7.58 🔺43.8%
buildStoryVisible 633ms 1.1s 515ms 8.15 🔺44.9%
buildAutodocsVisible 494ms 1s 591ms 8.6 🔺54.5%
buildMDXVisible 522ms 656ms 134ms 2.91 🔺20.4%

Greptile Summary

This PR updates the test addon's context menu UI to improve test status visualization and configuration, with major changes to error handling, component organization, and status management.

  • Added new GlobalErrorContext and GlobalErrorModal components for centralized error state management and display
  • Refactored TestProviderRender to support per-story test filtering and improved status handling with statusOrder and statusMap
  • Added new Title and Description components to improve code organization and reusability in context menu UI
  • Updated TestStatusIcon to include a new 'critical' status option and improved percentage-based visualization
  • Improved type safety by updating Addon_TestProviderType interface to include TestProviderConfig in state parameters

The changes appear well-structured and maintain core functionality while improving the UI and error handling capabilities. The PR includes proper type safety and follows React/TypeScript best practices.

💡 (5/5) You can turn off certain types of comments like style here!

Copy link

nx-cloud bot commented Nov 27, 2024

☁️ Nx Cloud Report

CI is running/has finished running commands for commit 9622f5c. As they complete they will appear below. Click to see the status, the terminal output, and the build insights.

📂 See all runs for this CI Pipeline Execution


✅ Successfully ran 1 target

Sent with 💌 from NxCloud.

@storybook-pr-benchmarking
Copy link

storybook-pr-benchmarking bot commented Nov 29, 2024

Package Benchmarks

Commit: 9622f5c, ran on 2 December 2024 at 15:26:59 UTC

No significant changes detected, all good. 👏

@ghengeveld ghengeveld marked this pull request as ready for review December 2, 2024 09:03
Copy link
Contributor

@greptile-apps greptile-apps bot left a comment

Choose a reason for hiding this comment

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

18 file(s) reviewed, 6 comment(s)
Edit PR Review Bot Settings | Greptile

@ghengeveld ghengeveld enabled auto-merge December 2, 2024 15:15
@ghengeveld ghengeveld merged commit dd16ceb into next Dec 2, 2024
60 checks passed
@ghengeveld ghengeveld deleted the context-menu-ui branch December 2, 2024 15:37
@github-actions github-actions bot mentioned this pull request Dec 2, 2024
11 tasks
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.

Improve UI for component tests in story menu
2 participants