Add <InPlaceEditor> for edit-in-place#10690
Conversation
1c44b61 to
078ba46
Compare
|
Switching to RFR |
slax57
left a comment
There was a problem hiding this comment.
Other than that this new component works very well and the UX is 👌
|
Thanks for the great review, I've taken most of your comments into account and added my comments where I disagree. |
|
To use this in Or could some prop be added to enable that behavior? |
|
@dalen Integrating For editable datagrid, we recommend using |
Problem
To edit a value from a record, users have to leave the current screen to go to an Edit view (or use
EditInDialog, but they will also lose context).Solution
<InPlaceEditor>renders a field from the current record. On click, it switches to an editable state, allowing the user to change the value directly.InPlaceEditor.mp4
Use this component to let users edit parts of a record directly in the list or detail view. It is useful for quick edits without navigating to a separate edit page.
The field changes color on hover, to indicate that it is editable. The user can cancel the edit by pressing Escape. The field is saved automatically when the user clicks outside of it or presses Enter. While it is being saved, the field is disabled and a loading spinner is shown. If the save fails, an error message is displayed and the original value is restored.
This component can even help replace the
<EditableDatagrid>:InPlaceEditorDataTable.mov
How To Test
http://localhost:9010/?path=/story/ra-ui-materialui-input-inplaceeditor--basic
Additional Checks
masterfor a bugfix or a documentation fix, ornextfor a feature