Made an attempt of extending the gadget to allow copying references between different items:
To allow copying references between different tabs/windows, I'm using localStorage, but as a clean-up measure I remove items that are more than 4 hours old.
I'm not sure if this is the best way to implement this – or if the feature is even wanted by anyone else than me, so any feedback is welcome.
Also wonder if there is there is some event that fires when all of the DOM is ready, including the .wikibase-toolbar-button-add links? I had to add a small setTimeout() now, or they would not be there, but that's messy.