Website link
name | label | placeholder | required | type | onclick |
website | Website | https://montaigne.io | true | url | |
link-title | Link title | Text to display | text | ||
website-link-btn | Copy | button | var copyBtn=this;var text = document.getElementById('website').value;var linkTitle = document.getElementById('link-title').value || text;var outputValue='<a href='+text+'>'+linkTitle+'</a>';var blob = new Blob([outputValue], { type: 'text/html' });var richTextInput = new ClipboardItem({ 'text/html': blob });navigator.clipboard.write([richTextInput]).then(function(){copyBtn.setAttribute('title', 'Copied');setTimeout(function(){copyBtn.setAttribute('title', 'Copy');}, 5000)}); |
Email link
name | label | placeholder | required | type | onclick |
hi@montaigne.io | true | ||||
link-title | Link title | Text to display | text | ||
email-link-btn | Copy | button | var copyBtn=this;var text = document.getElementById('email').value;var linkTitle = document.getElementById('link-title').value || text;var outputValue='<a href=mailto:'+text+'>'+linkTitle+'</a>';var blob = new Blob([outputValue], { type: 'text/html' });var richTextInput = new ClipboardItem({ 'text/html': blob });navigator.clipboard.write([richTextInput]).then(function(){copyBtn.setAttribute('title', 'Copied');setTimeout(function(){copyBtn.setAttribute('title', 'Copy');}, 5000)}); |
Phone link
name | label | placeholder | required | type | onclick |
phone | Phone | 555-55-55 | true | phone | |
link-title | Link title | Text to display | text | ||
email-link-btn | Copy | button | var copyBtn=this;var text = document.getElementById('phone').value;var linkTitle = document.getElementById('link-title').value || text;var outputValue='<a href=tel:'+text+'>'+linkTitle+'</a>';var blob = new Blob([outputValue], { type: 'text/html' });var richTextInput = new ClipboardItem({ 'text/html': blob });navigator.clipboard.write([richTextInput]).then(function(){copyBtn.setAttribute('title', 'Copied');setTimeout(function(){copyBtn.setAttribute('title', 'Copy');}, 5000)}); |