To copy content to clipboard, use the toClipboard
action as follows:
toClipboard: .copied-element-class-name, COPIED!
- the first parameter refers to the class of the element whose content we want to copy
- the second parameter contains the text that appears in the button after successful copying
<button onclick="mailocator.do('toClipboard: .copied-element-class-name, COPIED!')">COPY</button>