Add support for arbitrary number of rows & columns in selection grid