scratch
/link.html |
@@ -63,6 +63,12 @@ |
<button id="copy-url" class="btn btn-default" type="button" data-clipboard-target="#URL" data-toggle="tooltip" data-placement="auto" title="Copy to clipboard."><i class="glyphicon glyphicon-paperclip"></i></button> |
</span> |
</div> |
<div class="input-group"> |
<input id="deleteURL" type="text" class="form-control" readonly> |
<span class="input-group-btn"> |
<button id="delete-url" class="btn btn-default" type="button" data-clipboard-target="#deleteURL"><i class="glyphicon glyphicon-paperclip"></i></button> |
</span> |
</div> |
</div> |
</form> |
</div> |
@@ -132,11 +138,23 @@ |
.concat("/") |
.concat(data.hash) |
); |
|
$('#deleteURL') |
.val( |
location |
.protocol.concat("//") |
.concat(window.location.hostname) |
.concat("/") |
.concat(data.timestamp) |
.concat("/") |
.concat(data.hash) |
); |
}); |
}); |
|
// Enable the Clipboard button. |
new Clipboard('#copy-url'); |
new Clipboard('#delete-url'); |
|
// Scroll to the panel. |
$('html, body').animate({ |