Added copyToClipboard function