scratch – Diff between revs 84 and 90

Subversion Repositories:
Rev:
Show entire fileIgnore whitespace
Rev 84 Rev 90
Line 85... Line 85...
85 <input id="URL" type="text" class="form-control" readonly> 85 <input id="URL" type="text" class="form-control" readonly>
86 <span class="input-group-btn"> 86 <span class="input-group-btn">
87 <button id="btn-mailto" class="btn btn-default" type="button"><i class="glyphicon glyphicon-envelope"></i></button> 87 <button id="btn-mailto" class="btn btn-default" type="button"><i class="glyphicon glyphicon-envelope"></i></button>
88 </span> 88 </span>
89 <span class="input-group-btn"> 89 <span class="input-group-btn">
-   90 <button id="btn-facebook" class="btn btn-default" type="button" disabled="disabled"><i class="fa fa-facebook"></i></button>
-   91 </span>
-   92 <span class="input-group-btn">
90 <button id="btn-clipboard" class="btn btn-default" type="button"><i class="glyphicon glyphicon-paperclip"></i></button> 93 <button id="btn-clipboard" class="btn btn-default" type="button"><i class="glyphicon glyphicon-paperclip"></i></button>
91 </span> 94 </span>
92 </div> 95 </div>
93 <div class="input-group"> 96 <div class="input-group">
94 <input id="deleteURL" type="text" class="form-control" readonly> 97 <input id="deleteURL" type="text" class="form-control" readonly>
Line 298... Line 301...
298 $('#' + mailToButtonID).on('click', () => { 301 $('#' + mailToButtonID).on('click', () => {
299 window.location.href = "mailto:?subject="+ 302 window.location.href = "mailto:?subject="+
300 encodeURIComponent("Can't scratch this!") + "&body=" + 303 encodeURIComponent("Can't scratch this!") + "&body=" +
301 encodeURIComponent($('#' + boxURLID).val()); 304 encodeURIComponent($('#' + boxURLID).val());
302 }); 305 });
-   306
-   307 // Set the ID of the facebook button.
-   308 const faceBookButtonID = '_' + Math
-   309 .random()
-   310 .toString(36)
-   311 .substr(2, 9);
-   312  
-   313 file
-   314 .previewElement
-   315 .querySelector("#btn-facebook")
-   316 .setAttribute('id', faceBookButtonID);
-   317
-   318 switch(data.opengraph) {
-   319 case true:
-   320 // Enable the facebook button.
-   321 file
-   322 .previewElement
-   323 .querySelector('#' + faceBookButtonID)
-   324 .removeAttribute("disabled");
-   325
-   326 // Change the URL when the user clicks the button.
-   327 $('#' + faceBookButtonID).on('click', () => {
-   328 $('#' + boxURLID)
-   329 .val(
-   330 location.protocol.concat("//")
-   331 .concat(window.location.hostname)
-   332 .concat("/")
-   333 .concat("og")
-   334 .concat("/")
-   335 .concat(data.hash)
-   336 );
-   337 });
-   338 break;
-   339 default:
-   340 // Disable the facebook button.
-   341 file
-   342 .previewElement
-   343 .querySelector('#' + faceBookButtonID)
-   344 .setAttribute("disabled", "disabled");
-   345 break;
-   346 }
303 }); 347 });
Line 304... Line 348...
304 348
305 document.querySelector("#actions .start").onclick = () => { 349 document.querySelector("#actions .start").onclick = () => {
306 myDropzone.enqueueFiles( 350 myDropzone.enqueueFiles(