Adafruit NeoKey 5x6 Ortho Snap-Apart Mechanical Key Switches with NeoPixel has 30 key switches that can be snapped apart to make any size grid.
Even though it comes as 5x6, you can turn it into 2x3, 1x6, 4x3...whatever you wish, and it will work just the way you expect.
Each 'sub-key' is the same - with a column and row line that is diode protected. For whatever grid size you eventually choose, connect a digital IO pin from your microcontroller to each of the outer rows and columns. With the diode, you don't have to worry about key ghosting.
Each key also has a single reverse-mount NeoPixel pointing up through the spot where many switches would have an LED to shine through. Connect 3 to 5V power to any of the + and - pins on the grid, and connect a single digital IO line to the beginning of the 'NeoPixel snake' that winds its way through the matrix. A weak 2.2K pass-through resistor will shunt data through at the end of each row, so you don't have to do any jumpering unless the matrix is not-rectangular.
Every breakout has a Kailh socket, which means you can plug in any MX-compatible switch instead of soldering it in. You may need a little glue to keep the switch in place: hot glue or a dot of epoxy worked fine for us.
Please note, each order comes with one sheet of assembled PCBs that can be broken apart - we include top and bottom railing bits to help keep it nice and flat during shipment. Once the grid is broken, you could jumper the breakout pads together to re-connect but it won't be very fun. Mechanical switches and keycaps are not included! Use any MX-compatible switch: Kailh, Gateron, etc all work!
Product Dimensions: 115.0mm x 115.0mm x 3.5mm
Product Weight: 41.7g