-
Notifications
You must be signed in to change notification settings - Fork 75
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
Add StudioTextarea and StudioTextfield components #12323
Conversation
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #12323 +/- ##
==========================================
+ Coverage 86.70% 86.73% +0.03%
==========================================
Files 1200 1205 +5
Lines 18070 18109 +39
Branches 2290 2292 +2
==========================================
+ Hits 15667 15707 +40
+ Misses 2122 2121 -1
Partials 281 281 ☔ View full report in Codecov by Sentry. |
e4581a8
to
5e9851f
Compare
9509839
to
963eac2
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks very good! Nice tests 💯
However, I believe that both textfield
and textarea
should be replaced by textField
and textArea
all places 😬
frontend/libs/studio-components/src/components/StudioTextarea/StudioTextarea.test.tsx
Show resolved
Hide resolved
frontend/libs/studio-components/src/components/StudioTextarea/StudioTextarea.test.tsx
Outdated
Show resolved
Hide resolved
frontend/libs/studio-components/src/components/StudioTextarea/StudioTextarea.test.tsx
Show resolved
Hide resolved
frontend/libs/studio-components/src/components/StudioTextfield/StudioTextfield.test.tsx
Show resolved
Hide resolved
frontend/libs/studio-components/src/components/StudioTextfield/StudioTextfield.test.tsx
Show resolved
Hide resolved
frontend/libs/studio-components/src/components/StudioTextarea/StudioTextarea.test.tsx
Show resolved
Hide resolved
frontend/libs/studio-components/src/components/StudioTextfield/StudioTextfield.test.tsx
Outdated
Show resolved
Hide resolved
…StudioTextarea.test.tsx Co-authored-by: andreastanderen <71079896+standeren@users.noreply.github.com>
…/StudioTextfield.test.tsx Co-authored-by: andreastanderen <71079896+standeren@users.noreply.github.com>
Thank you for your review, @standeren. I appreciate your feedback.
When it comes to casing, my opinion is that we should follow the casing used in the design system to keep consistency. The design system components are again referring to primitive HTML components, which are case insensitive, but generally referred by lowercase letters only. (Also, I'm not a fan of exaggerated camel/pascal-casing.) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice 🌟
…omponent # Conflicts: # frontend/libs/studio-components/src/components/StudioDecimalInput/StudioDecimalInput.tsx
Description
Added a textarea component to the component library. The component adds the possibility to provide an error mssage that will not be visible until the user blurs the field. It will then remain visible until the user empties the field. The implementation of the validation that makes the error message occur must be done independent from this.
Update: Added
StudioTextfield
(moved the code fromAltinnTextField
) and created a shared hook for the two components.Related Issue(s)
Verification