It works!

It's not very pretty, but the basic functionality is there