Skip to content

Instantly share code, notes, and snippets.

@passcod
Created December 23, 2022 04:32

Revisions

  1. passcod created this gist Dec 23, 2022.
    43 changes: 43 additions & 0 deletions twitter-stats-order.user.css
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,43 @@
    /* ==UserStyle==
    @name Twitter.com reorder stats
    @namespace github.com/openstyles/stylus
    @version 1.0.0
    @description Moves the new stats button after the regular stuff.
    @author passcod
    ==/UserStyle== */

    @-moz-document url-prefix("twitter.com/home") {
    article [role="group"] > :nth-child(1) {
    order: 1;
    }

    article [role="group"] > :nth-child(5) {
    order: 2;
    }
    }

    @-moz-document regexp("https://twitter.com/.+/status/[0-9]+") {
    article [role="group"] > :nth-child(1) {
    order: 1;
    }

    article [role="group"] > :nth-child(5) {
    order: 2;
    }

    article[tabindex="-1"] [role="group"] > div {
    gap: 20px;
    }

    article[tabindex="-1"] [role="group"] > div > div {
    margin: 0;
    }

    article[tabindex="-1"] [role="group"] > div > :nth-child(1) {
    order: 1;
    }

    article[tabindex="-1"] [role="group"] > div > :nth-child(5) {
    order: 2;
    }
    }