fix: added save button to table component to improve consistency #6663
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This pull request includes significant enhancements to the
TableNodeComponent
and theTableModal
components to improve the handling of temporary values and modal state management. The most important changes include the introduction of temporary state management for table values, the addition of modal open state handling, and the implementation of save and cancel functionality in the modal.Enhancements to
TableNodeComponent
:tempValue
state to manage temporary table values and updated relevant functions to usetempValue
instead ofvalue
. [1] [2] [3]isModalOpen
state to manage the modal's open state.handleSave
andhandleCancel
functions to handle save and cancel actions in the modal.Enhancements to
TableModal
:TableModalProps
to includeopen
,setOpen
,onSave
, andonCancel
properties.TableModal
component to handle the newopen
,setOpen
,onSave
, andonCancel
properties, including triggering the appropriate callbacks. [1] [2] [3]These changes collectively improve the user experience by providing better control over table data modifications and modal interactions.