mirror of
https://github.com/jgthms/bulma
synced 2026-03-15 02:04:29 -07:00
Add new intro
This commit is contained in:
@@ -160,6 +160,31 @@ document.addEventListener('DOMContentLoaded', function () {
|
||||
}
|
||||
});
|
||||
|
||||
var npmClipboard = new Clipboard('#npmCopy');
|
||||
|
||||
npmClipboard.on('onclick', function (e) {
|
||||
console.log('CLICK');
|
||||
});
|
||||
|
||||
npmClipboard.on('success', function (e) {
|
||||
e.trigger.innerText = 'copied!';
|
||||
e.trigger.classList.add('is-success');
|
||||
setTimeout(function () {
|
||||
e.trigger.innerText = 'copy';
|
||||
e.trigger.classList.remove('is-success');
|
||||
}, 500);
|
||||
e.clearSelection();
|
||||
});
|
||||
|
||||
npmClipboard.on('error', function (e) {
|
||||
e.trigger.innerText = 'error!';
|
||||
e.trigger.classList.add('is-error');
|
||||
setTimeout(function () {
|
||||
e.trigger.innerText = 'copy';
|
||||
e.trigger.classList.remove('is-error');
|
||||
}, 500);
|
||||
});
|
||||
|
||||
// Functions
|
||||
|
||||
function getAll(selector) {
|
||||
|
||||
Reference in New Issue
Block a user