Sure, here's a sample implementation of a Tetris shape generator written in a single HTML file using JavaScript:
This implementation creates a canvas element where the shapes will be drawn. It defines an array of Tetris shapes and uses the `generateShape` function to randomly select a shape. The `drawShape` function is used to draw the shape on the canvas. When the page is loaded, a new shape is generated and drawn on the canvas.