IBM / carbon-ui-builder

Build Carbon UI components for your product in a fraction of time that it normally takes.
https://builder.carbondesignsystem.com/
Apache License 2.0
82 stars 42 forks source link

Autoremove empty rows from grid #154

Open zvonimirfras opened 2 years ago

zvonimirfras commented 2 years ago

When user removes all the cells from a grid row, it leaves a ghost 👻 row that's invisible in UI. It should be removed since that was likely user's intent.

JoelLau commented 2 years ago

i would like to take a stab at this! would anyone be kind enough to point me to the right component?

zvonimirfras commented 2 years ago

Sure, thing, thanks for doing this, @JoelLau! 😃

zvonimirfras commented 2 years ago

i would like to take a stab at this! would anyone be kind enough to point me to the right component?

I just realized I haven't pointed you to the component 😅

It's a grid component. Grid component uses several components to function - Grid, Row, and Column.

Removing empty rows will likely be easiest to do in the AGrid component when the state is updated, but you'll know more when you poke around a bit.

Will this be enough to get you started, @JoelLau?

Feel free to reach out to me here, on discord (Zvonimir#9989), or anywhere else (I'm easy to find 🙂)

JoelLau commented 2 years ago

sorry! it sounds like enough. i'll start working on it tomorrow (:

JoelLau commented 2 years ago

took a while, but i'm not sure if there're edge cases i'm not considering or if i'm conforming to the code style. lmk!