anmcgrath / BlazorDatasheet

Simple excel-like datasheet Blazor component
MIT License
131 stars 31 forks source link

Bug: Insert/Remove Cols/Rows not working #70

Closed lucasmoraiss closed 1 month ago

lucasmoraiss commented 1 month ago

When implementing the Inserting/Removing Cols/Rows button, I noticed that it wasn't working properly, it was adding blank spaces and it actually required the user to select a field to work, I think it could just add a new one to the end.

I tried it out on your deployed version and got the same result:

image

I also noticed that when you scroll to the start of the page and then scroll back, the insert/remove action that you did will appear, instead of the blank spaces. Maybe this help you to debug and find the solution quicker. It's just pretty unconsistent.

ADefWebserver commented 1 month ago

I saw that too. I think it is because the sheet is declared with only 100 rows and columns:

Sheet = new Sheet(100, 100);

anmcgrath commented 1 month ago

@lucasmoraiss thanks for reporting, it's a bug with the code that refreshes the view after changes have been made. I'll have a look at it.