File tree 3 files changed +8
-3
lines changed
3 files changed +8
-3
lines changed Original file line number Diff line number Diff line change 1
1
# Change Log
2
2
3
+ ## 4.10.3
4
+ > Date: 2023-02-15
5
+ ### Fix
6
+ - Fix paste issue when editing
7
+
3
8
## 4.10.2
4
9
> Date: 2023-02-08
5
10
### Fix
Original file line number Diff line number Diff line change 1
1
{
2
2
"name" : " react-datasheet-grid" ,
3
- "version" : " 4.10.2 " ,
3
+ "version" : " 4.10.3 " ,
4
4
"description" : " An Excel-like React component to create beautiful spreadsheets." ,
5
5
"main" : " dist/index.js" ,
6
6
"types" : " dist/index.d.ts" ,
Original file line number Diff line number Diff line change @@ -857,7 +857,7 @@ export const DataSheetGrid = React.memo(
857
857
858
858
const onPaste = useCallback (
859
859
( event : ClipboardEvent ) => {
860
- if ( activeCell ) {
860
+ if ( activeCell && ! editing ) {
861
861
let pasteData = [ [ '' ] ]
862
862
if ( event . clipboardData ?. types . includes ( 'text/html' ) ) {
863
863
pasteData = parseTextHtmlData (
@@ -876,7 +876,7 @@ export const DataSheetGrid = React.memo(
876
876
event . preventDefault ( )
877
877
}
878
878
} ,
879
- [ activeCell , applyPasteDataToDatasheet ]
879
+ [ activeCell , applyPasteDataToDatasheet , editing ]
880
880
)
881
881
882
882
useDocumentEventListener ( 'paste' , onPaste )
You can’t perform that action at this time.
0 commit comments