Skip to content

Conversation

@FrederikBolding
Copy link
Member

@FrederikBolding FrederikBolding commented Apr 2, 2025

Makes a couple of improvements to the interactive UI example Snap:

  • Use custom dialog type with footers instead of regular buttons
  • Add a disabled parameter which disables all of the components for testing and visual inspection
  • Remove broken "Get interface state" button

image

@FrederikBolding FrederikBolding requested a review from a team as a code owner April 2, 2025 12:52
@codecov
Copy link

codecov bot commented Apr 2, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 94.87%. Comparing base (1760a18) to head (a59ea83).
Report is 2 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #3293   +/-   ##
=======================================
  Coverage   94.87%   94.87%           
=======================================
  Files         517      517           
  Lines       11333    11335    +2     
  Branches     1748     1749    +1     
=======================================
+ Hits        10752    10754    +2     
  Misses        581      581           

☔ 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.


export const InteractiveForm: SnapComponent = () => {
export const InteractiveForm: SnapComponent<{ disabled?: boolean }> = ({
disabled,
Copy link
Member

Choose a reason for hiding this comment

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

Maybe just add a few disabled elements instead of a prop to disable everything?

Copy link
Member Author

Choose a reason for hiding this comment

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

Ideally we want to show each component's disabled state, it would duplicate a lot to introduce each component in its disabled state too 🤔

Copy link
Member Author

Choose a reason for hiding this comment

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

IMO it is neat that we can test the submit button being disabled too, would be kinda hard without a disabled state

@FrederikBolding FrederikBolding requested a review from Mrtenz April 2, 2025 14:02
@FrederikBolding FrederikBolding added this pull request to the merge queue Apr 2, 2025
Merged via the queue into main with commit 8bfaf95 Apr 2, 2025
172 checks passed
@FrederikBolding FrederikBolding deleted the fb/improve-interactive-ui-example branch April 2, 2025 14:12
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.

3 participants