I've been thinking about this idea for so long and have never really settled on the right design, but to heck with it, this is version 1.0!
Step 1: Stuff you need
The trouble with this whole idea is that every tub seems to be a little different, so this is pretty much a one off based on the design of my bathtub. I would have considered using suction cups, but they don't stick to the textured surface of my tub, so that won't work.
desk surface: Some sort of sturdy material, preferably sheet plastic of some kind.
two shelf braces.
nuts and bolts.
waterproofing chemicals (Varathane or something like that)
pin vise, drill
coping saw or similar
Step 2: Measure, cut
To cut the fiberboard I used repeated careful strokes along the edge of a t-square until I finally made my way through the material. This took about 30 repeated passes, but I wanted a clean cut.
Step 3: Assemble
Just attach the shelf brackets to the back of the board with the bolt and nut.