-
Notifications
You must be signed in to change notification settings - Fork 841
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
[EuiInlineEdit] Allow EuiInlineEdit
to be used as a controlled component
#7157
[EuiInlineEdit] Allow EuiInlineEdit
to be used as a controlled component
#7157
Commits on Aug 25, 2023
-
[Setup] Create three new props to allow inline edit to be used as a c…
…ontrolled component
Configuration menu - View commit details
-
Copy full SHA for 39b7818 - Browse repository at this point
Copy the full SHA 39b7818View commit details -
[EuiInlineEdit] Implement control logic
- Created a DRY useMemo hook to handle switching/updating the value to be used in both read mode/edit mode and between controlled vs uncontrolled configurations - Replace readMode/editMode state variables with useMemo value - Pass new onChange & onCancel props to their respective functions within Inline Edit Form
Configuration menu - View commit details
-
Copy full SHA for d3862c5 - Browse repository at this point
Copy the full SHA d3862c5View commit details -
[EuiInlineEdit] Bug Fix & Cleanup
- Remove the unnecessary passing of inline edit form props from EuiInlineEditText and EuiInlineEditTitle. These components we both importing props like defaultValue, placeholder, etc from InlineEditForm just send them back unchanged. The props transformed / changed within Text and Title remain while the others have been removed. - Spread {...rest} to the InlineEditForm container div. It was being passed by Text and Title, but was never used. - Updated snapshots to relflect the above change
Configuration menu - View commit details
-
Copy full SHA for 53d5b38 - Browse repository at this point
Copy the full SHA 53d5b38View commit details
Commits on Sep 5, 2023
-
[EuiInlineEdit] Update the test cases for Inline Edit Form by creatin…
…g a section dedicated to the props specific to creating a controlled component
Configuration menu - View commit details
-
Copy full SHA for a643cc5 - Browse repository at this point
Copy the full SHA a643cc5View commit details -
Configuration menu - View commit details
-
Copy full SHA for 08c5c30 - Browse repository at this point
Copy the full SHA 08c5c30View commit details -
Configuration menu - View commit details
-
Copy full SHA for 977b3d5 - Browse repository at this point
Copy the full SHA 977b3d5View commit details -
Configuration menu - View commit details
-
Copy full SHA for c0f031c - Browse repository at this point
Copy the full SHA c0f031cView commit details
Commits on Sep 7, 2023
-
- Inline Edit Text & Title - add the isReadOnly prop back (it was removed when refactoring these two child components by accident) - Architecture updates from PR feedback
Configuration menu - View commit details
-
Copy full SHA for 433ff26 - Browse repository at this point
Copy the full SHA 433ff26View commit details -
[PR Feedback] Small update to documentation copy and example for usin…
…g inline edit as a controlled component
Configuration menu - View commit details
-
Copy full SHA for a0dedea - Browse repository at this point
Copy the full SHA a0dedeaView commit details -
- Update unit tests to have more specific names and test assertions - Added an additional test for onSave validation
Configuration menu - View commit details
-
Copy full SHA for 627b33d - Browse repository at this point
Copy the full SHA 627b33dView commit details -
- Add undefined fallback for placeholder for snapshot readability - Unit test copy and functionality updates
Configuration menu - View commit details
-
Copy full SHA for a180fb1 - Browse repository at this point
Copy the full SHA a180fb1View commit details
Commits on Sep 8, 2023
-
[PR Feedback] Add comment explaining placeholder fallback. Update uni…
…t test cases for clarity in functionality
Configuration menu - View commit details
-
Copy full SHA for f98c6fb - Browse repository at this point
Copy the full SHA f98c6fbView commit details -
Configuration menu - View commit details
-
Copy full SHA for 4bacd73 - Browse repository at this point
Copy the full SHA 4bacd73View commit details