This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
twitter.com##div[data-testid="cellInnerDiv"]:has(h2):has-text(Discover more) ~ * | |
twitter.com##div[data-testid="cellInnerDiv"]:has(h2):has-text(Discover more) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// transform cropper dataURI output to a Blob which Dropzone accepts | |
function dataURItoBlob(dataURI) { | |
var byteString = atob(dataURI.split(',')[1]); | |
var ab = new ArrayBuffer(byteString.length); | |
var ia = new Uint8Array(ab); | |
for (var i = 0; i < byteString.length; i++) { | |
ia[i] = byteString.charCodeAt(i); | |
} | |
return new Blob([ab], { type: 'image/jpeg' }); | |
} |