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

feat(protocol-designer): add TextAreaField component to protocol-designer #17487

Merged
merged 5 commits into from
Feb 11, 2025

Conversation

koji
Copy link
Contributor

@koji koji commented Feb 10, 2025

Overview

add TextAreaField component to protocol-designer and replace StyledTextarea in AddMetaData component with the new component.
The rest of replacing will be done by a following PR.
not adding to components because of review requests.

close AUTH-985 AUTH-1434

Test Plan and Hands on Testing

  • create a new protocol and TextAreaField works as well as InputField in AddMetaData component
  • run Storybook Protocol-Designer

Changelog

  • add TextAreaField component
  • add test for the component
  • add stories for the component
  • replace StyledTextArea in AddMetaData component with the new component

Review requests

TextAreaField uses a custom hook to track focus and focus-visible correclty.
focus-within is triggered and it shows the outer outline style when clicking TextArea
If you have any idea to trigger focus-visible and focus separately without using a custom hook, let me know.

Risk assessment

low

koji added 4 commits February 8, 2025 18:07
…ce textarea in addmetadata

add textarea for protocol-designer and replace textarea in addmetadata

close AUTH-985
…gner

add TextAreaField component to protocol-designer

close AUTH-
Copy link

codecov bot commented Feb 10, 2025

Codecov Report

Attention: Patch coverage is 87.64045% with 22 lines in your changes missing coverage. Please review.

Project coverage is 20.17%. Comparing base (2ec42e1) to head (b31a059).
Report is 10 commits behind head on edge.

Files with missing lines Patch % Lines
...col-designer/src/molecules/TextAreaField/index.tsx 86.90% 22 Missing ⚠️
Additional details and impacted files

Impacted file tree graph

@@            Coverage Diff             @@
##             edge   #17487      +/-   ##
==========================================
+ Coverage   20.09%   20.17%   +0.08%     
==========================================
  Files        3191     3192       +1     
  Lines      230123   230396     +273     
  Branches     8204     8276      +72     
==========================================
+ Hits        46246    46491     +245     
- Misses     183877   183905      +28     
Flag Coverage Δ
protocol-designer 17.50% <87.64%> (+0.09%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Files with missing lines Coverage Δ
protocol-designer/src/molecules/index.ts 100.00% <100.00%> (ø)
.../src/pages/CreateNewProtocolWizard/AddMetadata.tsx 84.28% <100.00%> (-0.23%) ⬇️
...col-designer/src/molecules/TextAreaField/index.tsx 86.90% <86.90%> (ø)

... and 5 files with indirect coverage changes

@koji koji marked this pull request as ready for review February 10, 2025 23:44
@koji koji requested a review from a team as a code owner February 10, 2025 23:44
@koji koji removed the request for review from a team February 10, 2025 23:44
@ncdiehl11
Copy link
Collaborator

looks good! Is it intentional to have to tab twice to focus into this field? That differs from InputField
https://github.com/user-attachments/assets/e396a299-dc98-4710-b61b-31e12a61ea3c

@koji
Copy link
Contributor Author

koji commented Feb 11, 2025

looks good! Is it intentional to have to tab twice to focus into this field? That differs from InputField https://github.com/user-attachments/assets/e396a299-dc98-4710-b61b-31e12a61ea3c

I think that is InpufField issue since there is no information about the behavior.
I guess InputField was create a couple years ago and probably the current implementation doesn't align with the design perfectly.

@koji koji merged commit 731fb9e into edge Feb 11, 2025
16 checks passed
@koji koji deleted the feat_add-textarea-component branch February 11, 2025 20:14
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.

2 participants