Skip to content

Instantly share code, notes, and snippets.

@LukeTowers
Last active November 16, 2018 17:16
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save LukeTowers/159cfb84d2c71e27cf3baa876fe830da to your computer and use it in GitHub Desktop.
Save LukeTowers/159cfb84d2c71e27cf3baa876fe830da to your computer and use it in GitHub Desktop.
Clean Gmail's crap new design
javascript:(function(){ var style = document.createElement(%27style%27), styleContent = document.createTextNode(%27div[role=\%22main\%22] > div:not(:last-child):not([class=\%22\%22])[class] { height: 2.25em !important; } div[aria-label=\%22Side panel\%22] > div > div[role=\%22tablist\%22] { display: none !important; } div.no > div:last-child { display: none !important; } div.no:before { display: block !important; content: \%27\%27 !important; height: 1.35em !important; } div[role=\%22button\%22][tabindex=\%220\%22][gh=\%22cm\%22] { border-radius: 0 !important; width: calc(100% - 0.5em) !important; padding-right: 0 !important; margin-left: -0.5em !important; text-align: center !important; color: #FFF !important; background: rgba(0,0,0,0.5) !important; box-shadow: none !important; box-sizing: border-box !important; } div[role=\%22button\%22][tabindex=\%220\%22][gh=\%22cm\%22]:before { background: none !important; content: \%27+\%27 !important; font-size: 3em !important; line-height: 1em !important; } div[title] { border-radius: 0 !important; } div[role=\%22link\%22] > div > div > div { border-radius: 0 !important; vertical-align: middle !important; height: 16px !important; margin-top: -10px !important; } div[role=\%22checkbox\%22]:before { border-radius: 0 !important; left: 0px !important; right: 0px !important; } div[data-tooltip][data-tooltip-align=\%22r\%22] { border-radius: 0 !important; } div[href$=\%22service=mail\%22] { border-radius: 0 !important; background: rgba(0,0,0,0.5) !important; border: 1px solid rgba(255,255,255,0.4) !important; } div[data-tooltip][data-tooltip-align=\%22r\%22] > div > div:nth-of-type(1):not([role=\%22link\%22]) { display: none !important; } div[data-tooltip][data-tooltip-align=\%22r\%22] > div > div[role=\%22link\%22] + div { display: none !important; }%27); style.appendChild(styleContent ); var caput = document.getElementsByTagName(%27head%27); caput[0].appendChild(style); })();```
div[role="main"] > div:not(:last-child):not([class=""])[class] {
height: 2.25em;
}
div[aria-label="Side panel"] > div > div[role="tablist"] {
display: none;
}
div.no > div:last-child {
display: none;
}
div.no:before {
display: block;
content: '';
height: 1.35em;
}
div[role="button"][tabindex="0"][gh="cm"] {
border-radius: 0;
width: calc(100% - 0.5em);
padding-right: 0;
margin-left: -0.5em;
text-align: center;
color: #FFF;
background: rgba(0,0,0,0.5);
box-shadow: none;
box-sizing: border-box;
}
div[role="button"][tabindex="0"][gh="cm"]:before {
background: none;
content: '+';
font-size: 3em;
line-height: 1em;
}
div[title] {
border-radius: 0;
}
div[role="link"] > div > div > div {
border-radius: 0;
vertical-align: middle;
height: 16px;
margin-top: -10px;
}
div[role="checkbox"]:before {
border-radius: 0;
left: 0px;
right: 0px;
}
div[data-tooltip][data-tooltip-align="r"] {
border-radius: 0;
}
div[href$="service=mail"] {
border-radius: 0;
background: rgba(0,0,0,0.5);
border: 1px solid rgba(255,255,255,0.4);
}
div[data-tooltip][data-tooltip-align="r"] > div > div:nth-of-type(1):not([role="link"]) {
display: none;
}
div[data-tooltip][data-tooltip-align="r"] > div > div[role="link"] + div {
display: none;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment