Github Gist Compact View

Add custom styles to Sergi0's Gist pages

Stan na 13-03-2025. Zobacz najnowsza wersja.

Aby zainstalować ten skrypt, wymagana jest instalacje jednego z następujących rozszerzeń: Tampermonkey, Greasemonkey lub Violentmonkey.

Aby zainstalować ten skrypt, wymagana jest instalacje jednego z następujących rozszerzeń: Tampermonkey, Violentmonkey.

Aby zainstalować ten skrypt, wymagana jest instalacje jednego z następujących rozszerzeń: Tampermonkey, Violentmonkey.

Aby zainstalować ten skrypt, wymagana będzie instalacja rozszerzenia Tampermonkey lub Userscripts.

You will need to install an extension such as Tampermonkey to install this script.

Aby zainstalować ten skrypt, musisz zainstalować rozszerzenie menedżera skryptów użytkownika.

(Mam już menedżera skryptów użytkownika, pozwól mi to zainstalować!)

You will need to install an extension such as Stylus to install this style.

You will need to install an extension such as Stylus to install this style.

You will need to install an extension such as Stylus to install this style.

Będziesz musiał zainstalować rozszerzenie menedżera stylów użytkownika, aby zainstalować ten styl.

Będziesz musiał zainstalować rozszerzenie menedżera stylów użytkownika, aby zainstalować ten styl.

Musisz zainstalować rozszerzenie menedżera stylów użytkownika, aby zainstalować ten styl.

(Mam już menedżera stylów użytkownika, pozwól mi to zainstalować!)

// ==UserScript==
// @name         Github Gist Compact View
// @namespace    http://tampermonkey.net/
// @version      1
// @description  Add custom styles to Sergi0's Gist pages
// @author       Sergi0
// @match        https://gist.github.com/*
// @grant        GM_addStyle
// @icon         https://gist.github.com/favicon.ico
// @license      MIT
// ==/UserScript==

(function() {
    'use strict';
    GM_addStyle(`
         /* main container */
        .gist-snippet {margin-bottom:2px!important;}
         /* icon */
        #gist-pjax-container > div > div > div.col-9.col-md-9.col-12 > div > div.gist-snippet-meta.d-flex.flex-lg-row.flex-column.width-full > div > div.d-lg-inline-block.d-none.v-align-top.mt-1 > a{display:none!important;}
        /* code */
        .gist-snippet .js-gist-file-update-container.js-task-list-container {display: none;}
        /* links */
        #gist-pjax-container > div > div > div.col-9.col-md-9.col-12 > div > div.gist-snippet-meta.d-flex.flex-lg-row.flex-column.width-full > div > div.d-inline-block.px-lg-2.px-0 > span:nth-child(1){display:none;}
        /* date */
        #gist-pjax-container > div > div > div.col-9.col-md-9.col-12 > div > div.gist-snippet-meta.d-flex.flex-lg-row.flex-column.width-full > div > div.d-inline-block.px-lg-2.px-0 > div {display:none}
        /* font size */
        #gist-pjax-container > div > div > div.col-9.col-md-9.col-12 > div > div.gist-snippet-meta.d-flex.flex-lg-row.flex-column.width-full > div > div.d-inline-block.px-lg-2.px-0 > span.f6.color-fg-muted{font-size:14px!important;}
    `);
})();