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: replace trash icon in MRF steps #7885

Merged
merged 9 commits into from
Nov 15, 2024
Merged

Conversation

scottheng96
Copy link
Contributor

@scottheng96 scottheng96 commented Nov 13, 2024

Problem

In MRF workflow, blocks have trash icon (top right) giving users ability to delete the step in workflow. For baseline practice in UX, destructive actions should be hidden below the fold

Closes FRM-1905

Solution

  • Replace trash icon with pencil icon

  • Update logic upon clicking icon to 'edit step' instead of 'delete step'

  • First step has pencil icon now also, since users can't delete the first step, but can edit the first step

  • Users will not be able to click anywhere on the box to enter editing step, only on clicking of the pencil icon

  • Removed highlight/background change/cursor appearance when hovering the box

Before & After Screenshots

Subject Before After
Trash icon replaced with pencil icon (first step included) Screenshot 2024-11-13 at 10 39 57 AM Screenshot 2024-11-13 at 10 36 47 AM
On click Screenshot 2024-11-13 at 11 10 32 AM Screenshot 2024-11-13 at 11 11 11 AM
Additional changes to behavior or edit/cursor https://github.com/user-attachments/assets/6b45ec88-0467-4bd0-bdab-97d0e7fdee55

@scottheng96 scottheng96 marked this pull request as draft November 13, 2024 03:14
@scottheng96 scottheng96 self-assigned this Nov 13, 2024
@KenLSM
Copy link
Contributor

KenLSM commented Nov 13, 2024

We can also remove handleOpenDeleteModal property from type InactiveStepBlockProps as handleOpenDeleteModal is no longer referenced in the component.

This also means that we have to cascade the removal of handleOpenDeleteModal property on the parent component of <InactiveStepBlock />

@scottheng96 scottheng96 marked this pull request as ready for review November 13, 2024 08:06
Copy link
Contributor

@KenLSM KenLSM left a comment

Choose a reason for hiding this comment

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

LGTM but holding the approval first as I'm getting PM to review the changes in-lieu of Design.

Copy link

linear bot commented Nov 14, 2024

Copy link
Contributor

@KenLSM KenLSM left a comment

Choose a reason for hiding this comment

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

LGTM!

@scottheng96 scottheng96 merged commit 02bcba6 into develop Nov 15, 2024
16 of 18 checks passed
@scottheng96 scottheng96 deleted the fix/replace-trash-icon branch November 15, 2024 02:12
This was referenced Nov 17, 2024
@kevin9foong kevin9foong mentioned this pull request Nov 19, 2024
14 tasks
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