Last active
December 27, 2015 03:09
-
-
Save akuhn/7257131 to your computer and use it in GitHub Desktop.
Don’t like Twitter's new photo preview? Same here. Fixed.
This file contains 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
// ==UserScript== | |
// @name Disable Photo Preview on Twitter | |
// @namespace http://example.com | |
// @description hacked with love by @akuhn | |
// @include https://twitter.com/* | |
// @version 1 | |
// @grant none | |
// ==/UserScript== | |
function addGlobalStyle(css) { | |
var head, style; | |
head = document.getElementsByTagName('head')[0]; | |
if (!head) { return; } | |
style = document.createElement('style'); | |
style.type = 'text/css'; | |
style.innerHTML = css; | |
head.appendChild(style); | |
} | |
addGlobalStyle(".with-media-forward .cards-base .media-forward { max-height: 0px; }"); | |
addGlobalStyle(".with-media-forward.opened-tweet .media-forward { max-height: none; }"); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment