Skip to content

Instantly share code, notes, and snippets.

@xPaw
Last active August 7, 2025 11:54

Revisions

  1. xPaw revised this gist Aug 7, 2025. 1 changed file with 3 additions and 1 deletion.
    4 changes: 3 additions & 1 deletion adventofcode.user.js
    Original file line number Diff line number Diff line change
    @@ -1,7 +1,9 @@
    // ==UserScript==
    // @name Advent of Code Improvements
    // @description Improve font and size on adventofcode.com
    // @namespace https://gist.github.com/xPaw/4fffaf776fe14d15c9602991f51dbfa1
    // @updateURL https://gist.github.com/xPaw/4fffaf776fe14d15c9602991f51dbfa1
    // @updateURL https://gist.github.com/xPaw/4fffaf776fe14d15c9602991f51dbfa1/raw/adventofcode.user.js
    // @downloadURL https://gist.github.com/xPaw/4fffaf776fe14d15c9602991f51dbfa1/raw/adventofcode.user.js
    // @version 1.2
    // @author xPaw
    // @match https://adventofcode.com/*
  2. xPaw revised this gist Dec 1, 2024. 1 changed file with 2 additions and 2 deletions.
    4 changes: 2 additions & 2 deletions adventofcode.user.js
    Original file line number Diff line number Diff line change
    @@ -2,7 +2,7 @@
    // @name Advent of Code Improvements
    // @namespace https://gist.github.com/xPaw/4fffaf776fe14d15c9602991f51dbfa1
    // @updateURL https://gist.github.com/xPaw/4fffaf776fe14d15c9602991f51dbfa1
    // @version 1.1
    // @version 1.2
    // @author xPaw
    // @match https://adventofcode.com/*
    // @icon https://adventofcode.com/favicon.png
    @@ -15,7 +15,7 @@

    GM_addStyle(`
    body {
    font-family: 'JetBrains Mono', Consolas, monospace;
    font-family: 'JetBrains Mono', ui-monospace, monospace;
    font-weight: 400;
    font-size: 18px;
    max-width: 60em;
  3. xPaw revised this gist Oct 8, 2024. 1 changed file with 1 addition and 1 deletion.
    2 changes: 1 addition & 1 deletion adventofcode.user.js
    Original file line number Diff line number Diff line change
    @@ -2,7 +2,7 @@
    // @name Advent of Code Improvements
    // @namespace https://gist.github.com/xPaw/4fffaf776fe14d15c9602991f51dbfa1
    // @updateURL https://gist.github.com/xPaw/4fffaf776fe14d15c9602991f51dbfa1
    // @version 1.0
    // @version 1.1
    // @author xPaw
    // @match https://adventofcode.com/*
    // @icon https://adventofcode.com/favicon.png
  4. xPaw revised this gist Nov 28, 2023. 1 changed file with 1 addition and 0 deletions.
    1 change: 1 addition & 0 deletions adventofcode.user.js
    Original file line number Diff line number Diff line change
    @@ -37,6 +37,7 @@
    pre, code {
    font-family: inherit;
    font-variant-ligatures: none;
    }
    #sidebar {
  5. xPaw revised this gist Nov 28, 2023. 1 changed file with 2 additions and 1 deletion.
    3 changes: 2 additions & 1 deletion adventofcode.user.js
    Original file line number Diff line number Diff line change
    @@ -18,7 +18,7 @@
    font-family: 'JetBrains Mono', Consolas, monospace;
    font-weight: 400;
    font-size: 18px;
    max-width: 45em;
    max-width: 60em;
    min-width: unset;
    margin: 20px auto;
    padding: 0 20px;
    @@ -27,6 +27,7 @@
    p.wrap,
    article {
    width: unset;
    max-width: 45em;
    }
    header,
  6. xPaw revised this gist Nov 28, 2023. 1 changed file with 1 addition and 1 deletion.
    2 changes: 1 addition & 1 deletion adventofcode.user.js
    Original file line number Diff line number Diff line change
    @@ -18,7 +18,7 @@
    font-family: 'JetBrains Mono', Consolas, monospace;
    font-weight: 400;
    font-size: 18px;
    max-width: 60em;
    max-width: 45em;
    min-width: unset;
    margin: 20px auto;
    padding: 0 20px;
  7. xPaw revised this gist Nov 28, 2023. 1 changed file with 0 additions and 4 deletions.
    4 changes: 0 additions & 4 deletions adventofcode.user.js
    Original file line number Diff line number Diff line change
    @@ -47,10 +47,6 @@
    background: #000;
    }
    pre {
    overflow-x: auto;
    }
    pre > code:before {
    left: -6px;
    right: -6px;
  8. xPaw revised this gist Nov 28, 2023. 1 changed file with 9 additions and 4 deletions.
    13 changes: 9 additions & 4 deletions adventofcode.user.js
    Original file line number Diff line number Diff line change
    @@ -24,6 +24,7 @@
    padding: 0 20px;
    }
    p.wrap,
    article {
    width: unset;
    }
    @@ -46,11 +47,15 @@
    background: #000;
    }
    pre {
    overflow-x: auto;
    }
    pre > code:before {
    left: -6px;
    right: -6px;
    top: -6px;
    bottom: -6px;
    left: -6px;
    right: -6px;
    top: -6px;
    bottom: -6px;
    }
    `);

  9. xPaw revised this gist Nov 28, 2023. 1 changed file with 1 addition and 1 deletion.
    2 changes: 1 addition & 1 deletion adventofcode.user.js
    Original file line number Diff line number Diff line change
    @@ -15,7 +15,7 @@

    GM_addStyle(`
    body {
    font-family: 'JetBrains Mono', monospace;
    font-family: 'JetBrains Mono', Consolas, monospace;
    font-weight: 400;
    font-size: 18px;
    max-width: 60em;
  10. xPaw revised this gist Nov 28, 2023. 1 changed file with 2 additions and 1 deletion.
    3 changes: 2 additions & 1 deletion adventofcode.user.js
    Original file line number Diff line number Diff line change
    @@ -1,6 +1,7 @@
    // ==UserScript==
    // @name Advent of Code Improvements
    // @namespace https://xpaw.me/adventofcode
    // @namespace https://gist.github.com/xPaw/4fffaf776fe14d15c9602991f51dbfa1
    // @updateURL https://gist.github.com/xPaw/4fffaf776fe14d15c9602991f51dbfa1
    // @version 1.0
    // @author xPaw
    // @match https://adventofcode.com/*
  11. xPaw created this gist Nov 28, 2023.
    60 changes: 60 additions & 0 deletions adventofcode.user.js
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,60 @@
    // ==UserScript==
    // @name Advent of Code Improvements
    // @namespace https://xpaw.me/adventofcode
    // @version 1.0
    // @author xPaw
    // @match https://adventofcode.com/*
    // @icon https://adventofcode.com/favicon.png
    // @grant GM_addStyle
    // @run-at document-end
    // ==/UserScript==

    (function() {
    'use strict';

    GM_addStyle(`
    body {
    font-family: 'JetBrains Mono', monospace;
    font-weight: 400;
    font-size: 18px;
    max-width: 60em;
    min-width: unset;
    margin: 20px auto;
    padding: 0 20px;
    }
    article {
    width: unset;
    }
    header,
    article h2 {
    white-space: unset;
    }
    pre, code {
    font-family: inherit;
    }
    #sidebar {
    display: none;
    }
    code:before {
    border: 1px solid #666;
    background: #000;
    }
    pre > code:before {
    left: -6px;
    right: -6px;
    top: -6px;
    bottom: -6px;
    }
    `);

    const viewport = document.createElement('meta');
    viewport.name = 'viewport';
    viewport.content = 'width=device-width, initial-scale=1.0';
    document.head.append(viewport);
    })();