Skip to content

Elon Musk Poopifier by Xcogitaire

Screenshot of Elon Musk Poopifier

Details

AuthorXcogitaire

Licensehttps://creativecommons.org/licenses/by/4.0/

Categorytwitter.com, x.com

Created

Updated

Size15 kB

Statistics

Learn how we calculate statistics in the FAQ.

Failed to fetch stats.

Description

Sends Elon Musk to the poop dimension, or hides him entirely.

Notes

Requires Firefox 121, Chrome 105, or Edge 105; Uses custom properties and the :has selector quite liberally.

Fairly likely to break if the child ordering/data-testid's of the Twitter HTML change, which is also fairly likely, given…well, you know…the current situation.

Source code

Source code has over 10K characters, so we truncated it. You can inspect the full source code on install link.
/* ==UserStyle==
@name           Elon Musk Poopifier
@namespace      github.com/openstyles/stylus
@version        1.0.0
@description    Sends Elon Musk to the poop dimension. Toggle one line to hide him entirely.
@author         Xcogitaire
@license        https://creativecommons.org/licenses/by/4.0/
==/UserStyle== */
@import url('https://fonts.googleapis.com/css2?family=Comic+Neue:ital,wght@0,300;0,400;0,700;1,300;1,400;1,700&display=swap');
@-moz-document regexp("https:\\/\\/x\\.com(?!\\/elonmusk).*|https:\\/\\/twitter\\.com(?!\\/elonmusk).*") {
    article[data-testid="tweet"]:has(a[href="/elonmusk"] > div > span),
    article[data-testid="tweet"]:has(a[href="/elonmusk"] span[data-testid="socialContext"]) {

        /* SET THIS LINE TO `none` TO ENTIRELY AND UTTERLY UNMUSK */
        display: inherit;
        /* Why is this in a whole different section than the rest of this script? So that if, for some reason, you go on Elon Musk's profile, the page doesn't constantly try to load a bunch of tweets that it can't display*/
    }
}

@-moz-document domain("x.com"),
domain("twitter.com") {
    /* Poop Emoji SVG, Comic Sans-ish font */
    html {
        --poop-color: #3b2c1a;

        --poop-this-man: url("data:image/svg+xml,%3C%3Fxml version='1.0' encoding='UTF-8' standalone='no'%3F%3E%3Csvg xmlns:svg='http://www.w3.org/2000/svg' xmlns='http://www.w3.org/2000/svg' version='1.1' viewBox='0 0 47.5 47.5' style='enable-background:new 0 0 47.5 47.5;' id='svg2' xml:space='preserve'%3E%3Cdefs id='defs6'%3E%3CclipPath id='clipPath18'%3E%3Cpath d='M 0,38 38,38 38,0 0,0 0,38 z' id='path20'/%3E%3C/clipPath%3E%3C/defs%3E%3Cg transform='matrix(1.25,0,0,-1.25,0,47.5)' id='g12'%3E%3Cg id='g14'%3E%3Cg clip-path='url(%23clipPath18)' id='g16'%3E%3Cg transform='translate(34.541,13.8018)' id='g22'%3E%3Cpath d='m 0,0 c 0.364,1.578 0.243,3.266 -0.458,4.946 -0.678,1.625 -1.847,2.91 -3.271,3.773 0.319,1.193 0.235,2.475 -0.324,3.751 -0.841,1.92 -2.66,3.201 -4.712,3.562 0.249,0.572 0.329,1.288 0.036,2.167 -1,3 -5,1 -8,4.999 -2.439,-1.464 -2.969,-3.639 -2.877,-5.487 -2.422,-0.412 -3.8,-0.936 -3.8,-0.936 l 0,-0.002 c -1.361,-0.551 -2.323,-1.884 -2.323,-3.443 0,-0.879 0.318,-1.676 0.829,-2.312 l -0.692,-0.259 10e-4,-0.003 c -2.33,-0.87 -3.975,-2.976 -3.975,-5.439 0,-1.046 0.3,-2.027 0.82,-2.878 -2.824,-1.268 -4.795,-4.022 -4.795,-7.241 0,-4.418 3.691,-8 8.244,-8 3.269,0 6.559,0.703 9.531,1.665 2.243,-1.04 5.695,-1.665 10.892,-1.665 4.05,0 7.333,3.283 7.333,7.333 C 2.459,-3.293 1.506,-1.344 0,0' id='path24' style='fill:%23bf6952;fill-opacity:1;fill-rule:nonzero;stroke:none'/%3E%3C/g%3E%3Cg transform='translate(18,21.5)' id='g26'%3E%3Cpath d='M 0,0 C 0,-2.485 -1.567,-4.5 -3.5,-4.5 -5.433,-4.5 -7,-2.485 -7,0 -7,2.485 -5.433,4.5 -3.5,4.5 -1.567,4.5 0,2.485 0,0' id='path28' style='fill:%23f5f8fa;fill-opacity:1;fill-rule:nonzero;stroke:none'/%3E%3C/g%3E%3Cg transform='translate(28,21.5)' id='g30'%3E%3Cpath d='M 0,0 C 0,-2.485 -1.566,-4.5 -3.5,-4.5 -5.434,-4.5 -7,-2.485 -7,0 -7,2.485 -5.434,4.5 -3.5,4.5 -1.566,4.5 0,2.485 0,0' id='path32' style='fill:%23f5f8fa;fill-opacity:1;fill-rule:nonzero;stroke:none'/%3E%3C/g%3E%3Cg transform='translate(17,21.5)' id='g34'%3E%3Cpath d='m 0,0 c 0,-1.381 -0.896,-2.5 -2,-2.5 -1.104,0 -2,1.119 -2,2.5 0,1.381 0.896,2.5 2,2.5 1.104,0 2,-1.119 2,-2.5' id='path36' style='fill:%23292f33;fill-opacity:1;fill-rule:nonzero;stroke:none'/%3E%3C/g%3E%3Cg transform='translate(26,21.5)' id='g38'%3E%3Cpath d='m 0,0 c 0,-1.381 -0.896,-2.5 -2,-2.5 -1.104,0 -2,1.119 -2,2.5 0,1.381 0.896,2.5 2,2.5 1.104,0 2,-1.119 2,-2.5' id='path40' style='fill:%23292f33;fill-opacity:1;fill-rule:nonzero;stroke:none'/%3E%3C/g%3E%3Cg transform='translate(10.4473,12.1055)' id='g42'%3E%3Cpath d='m 0,0 c -0.246,0.492 0.003,0.895 0.553,0.895 l 18,0 c 0.55,0 0.799,-0.403 0.552,-0.895 0,0 -2.552,-5.105 -9.552,-5.105 C 2.553,-5.105 0,0 0,0' id='path44' style='fill:%23292f33;fill-opacity:1;fill-rule:nonzero;stroke:none'/%3E%3C/g%3E%3Cg transform='translate(20,11)' id='g46'%3E%3Cpath d='M 0,0 C -2.771,0 -5.157,-0.922 -6.292,-2.256 -4.8,-3.211 -2.747,-4 0,-4 2.747,-4 4.801,-3.211 6.292,-2.256 5.157,-0.922 2.771,0 0,0' id='path48' style='fill:%23f2abba;fill-opacity:1;fill-rule:nonzero;stroke:none'/%3E%3C/g%3E%3C/g%3E%3C/g%3E%3C/g%3E%3C/svg%3E%0A");

        --poop-this-quote: url("data:image/svg+xml,%3C%3Fxml version='1.0' encoding='UTF-8' standalone='no'%3F%3E%3Csvg xmlns:svg='http://www.w3.org/2000/svg' xmlns='http://www.w3.org/2000/svg' version='1.1' viewBox='0 0 47.5 47.5' style='enable-background:new 0 0 47.5 47.5;' id='svg2' xml:space='preserve'%3E%3Cdefs id='defs6'%3E%3CclipPath id='clipPath18'%3E%3Cpath d='M 0,38 38,38 38,0 0,0 0,38 z' id='path20'/%3E%3C/clipPath%3E%3C/defs%3E%3Cg transform='matrix(1.25,0,0,-1.25,0,47.5)' id='g12'%3E%3Cg id='g14'%3E%3Cg clip-path='url(%23clipPath18)' id='g16'%3E%3Cg transform='translate(34.541,13.8018)' id='g22'%3E%3Cpath d='m 0,0 c 0.364,1.578 0.243,3.266 -0.458,4.946 -0.678,1.625 -1.847,2.91 -3.271,3.773 0.319,1.193 0.235,2.475 -0.324,3.751 -0.841,1.92 -2.66,3.201 -4.712,3.562 0.249,0.572 0.329,1.288 0.036,2.167 -1,3 -5,1 -8,4.999 -2.439,-1.464 -2.969,-3.639 -2.877,-5.487 -2.422,-0.412 -3.8,-0.936 -3.8,-0.936 l 0,-0.002 c -1.361,-0.551 -2.323,-1.884 -2.323,-3.443 0,-0.879 0.318,-1.676 0.829,-2.312 l -0.692,-0.259 10e-4,-0.003 c -2.33,-0.87 -3.975,-2.976 -3.975,-5.439 0,-1.046 0.3,-2.027 0.82,-2.878 -2.824,-1.268 -4.795,-4.022 -4.795,-7.241 0,-4.418 3.691,-8 8.244,-8 3.269,0 6.559,0.703 9.531,1.665 2.243,-1.04 5.695,-1.665 10.892,-1.665 4.05,0 7.333,3.283 7.333,7.333 C 2.459,-3.293 1.506,-1.344 0,0' id='path24' style='fill:%23bf6952;fill-opacity:0.3;fill-rule:nonzero;stroke:none'/%3E%3C/g%3E%3Cg transform='translate(18,21.5)' id='g26'%3E%3Cpath d='M 0,0 C 0,-2.485 -1.567,-4.5 -3.5,-4.5 -5.433,-4.5 -7,-2.485 -7,0 -7,2.485 -5.433,4.5 -3.5,4.5 -1.567,4.5 0,2.485 0,0' id='path28' style='fill:%23f5f8fa;fill-opacity:0.25;fill-rule:nonzero;stroke:none'/%3E%3C/g%3E%3Cg transform='translate(28,21.5)' id='g30'%3E%3Cpath d='M 0,0 C 0,-2.485 -1.566,-4.5 -3.5,-4.5 -5.434,-4.5 -7,-2.485 -7,0 -7,2.485 -5.434,4.5 -3.5,4.5 -1.566,4.5 0,2.485 0,0' id='path32' style='fill:%23f5f8fa;fill-opacity:0.25;fill-rule:nonzero;stroke:none'/%3E%3C/g%3E%3Cg transform='translate(17,21.5)' id='g34'%3E%3Cpath d='m 0,0 c 0,-1.381 -0.896,-2.5 -2,-2.5 -1.104,0 -2,1.119 -2,2.5 0,1.381 0.896,2.5 2,2.5 1.104,0 2,-1.119 2,-2.5' id='path36' style='fill:%23292f33;fill-opacity:0.6;fill-rule:nonzero;stroke:none'/%3E%3C/g%3E%3Cg transform='translate(26,21.5)' id='g38'%3E%3Cpath d='m 0,0 c 0,-1.381 -0.896,-2.5 -2,-2.5 -1.104,0 -2,1.119 -2,2.5 0,1.381 0.896,2.5 2,2.5 1.104,0 2,-1.119 2,-2.5' id='path40' style='fill:%23292f33;fill-opacity:0.6;fill-rule:nonzero;stroke:none'/%3E%3C/g%3E%3Cg transform='translate(10.4473,12.1055)' id='g42'%3E%3Cpath d='m 0,0 c -0.246,0.492 0.003,0.895 0.553,0.895 l 18,0 c 0.55,0 0.799,-0.403 0.552,-0.895 0,0 -2.552,-5.105 -9.552,-5.105 C 2.553,-5.105 0,0 0,0' id='path44' style='fill:%23292f33;fill-opacity:0.6;fill-rule:nonzero;stroke:none'/%3E%3C/g%3E%3Cg transform='translate(20,11)' id='g46'%3E%3Cpath d='M 0,0 C -2.771,0 -5.157,-0.922 -6.292,-2.256 -4.8,-3.211 -2.747,-4 0,-4 2.747,-4 4.801,-3.211 6.292,-2.256 5.157,-0.922 2.771,0 0,0' id='path48' style='fill:%23f2abba;fill-opacity:0.2;fill-rule:nonzero;stroke:none'/%3E%3C/g%3E%3C/g%3E%3C/g%3E%3C/g%3E%3C/svg%3E%0A");
    }

    html[style*="color-scheme: dark"] {
        /* coincidentally this color kinda looks like it spells "caca", how fitting */
        --poop-color: #caac8a;
    }

    /* Profile pic of tweet that is from/retweeted by Elon Musk */
    article[data-testid="tweet"]:has(a[href="/elonmusk"] > div > span) div[data-testid="Tweet-User-Avatar"],
    article[data-testid="tweet"]:has(a[href="/elonmusk"] span[data-testid="socialContext"]) div[data-testid="Tweet-User-Avatar"] {
        display: block;
        position: relative;
    }

    article[data-testid="tweet"]:has(a[href="/elonmusk"] > div > span) div[data-testid="Tweet-User-Avatar"]::after,
    article[data-testid="tweet"]:has(a[href="/elonmusk"] span[data-testid="socialContext"]) div[data-testid="Tweet-User-Avatar"]::after {
        content: var(--poop-this-man);

        display: block;
        width: calc(100% + 2px);
        height: calc(100% + 2px);

        box-sizing: border-box;
        padding: 0.2em;

        position: absolute;
        top: -1px;
        left: -1px;
        z-index: 1;

        background-color: var(--hover-bg-color, #eee);
        background-repeat: no-repeat;
        background-position: center;
        background-size: cover;
        border-radius: 100%
    }

    /* Square profile pic (brand) that was retweeted by Elon Musk */
    article[data-testid="tweet"]:has(a[href="/elonmusk"] span[data-testid="socialContext"]) div[data-testid="Tweet-User-Avatar"]:has(div[style*="#shape-square"])::after {
        border-radius: 3px;
    }

    /* Tweet text of tweet/retweet that is from Elon Musk */
    article[data-testid="tweet"]:has(a[href="/elonmusk"] > div > span) div[data-testid="tweetText"],
    article[data-testid="tweet"]:has(a[href="/elonmusk"] span[data-testid="socialContext"]) div[data-testid="tweetText"] {
        position: relative;
        height: 1.5em;
    }

    article[data-testid="tweet"]:has(a[href="/elonmusk"] > div > span) div[data-testid="tweetText"] > *,
    article[data-testid="tweet"]:has(a[href="/elonmusk"] span[data-testid="socialContext"]) div[data-testid="tweetText"] > * {
        opacity: 0;
        overflow: clip !important;
        text-overflow: clip !important;
    }

    article[data-testid="tweet"]:has(a[href="/elonmusk"] > div > span) div[data-testid="tweetText"]::after,
    article[data-testid="tweet"]:has(a[href="/elonmusk"] span[data-testid="socialContext"]) div[data-testid="tweetText"]::after {
        content: "💩💩 pleeeeaaaase unhide my tweets 😭😭😭 i am very intelligent 💩...

Reviews

No reviews yet.