GitHub-userscripts icon indicating copy to clipboard operation
GitHub-userscripts copied to clipboard

Is there a script for extending the column width limit in code review?

Open amosbird opened this issue 4 years ago • 3 comments

I'm trying to have a 140 column width limit in the single page diff. Not sure if it's possible.

amosbird avatar May 31 '20 03:05 amosbird

Hi @amosbird!

There isn't a userscript, but you can click on the gear icon and choose "Split"

That will fill the entire browser width with a side-by-side view of the code.

If that doesn't work for you and you have Stylus installed, the you can install GitHub Wide (although that page doesn't seem to be loading for me). I think there are also a few chrome browser extensions that make GitHub full width.

Mottie avatar May 31 '20 14:05 Mottie

Actually, try this userscript... it really only needs a minimal amount of css to work:

// ==UserScript==
// @name        GitHub Wide
// @version     0.1.0
// @description A userscript that adds a color swatch next to the code color definition
// @license     MIT
// @author      Rob Garrison
// @namespace   https://github.com/Mottie
// @include     https://github.com/*
// @run-at      document-idle
// @grant       GM_addStyle
// ==/UserScript==

(function() {
  "use strict";

  GM_addStyle(`
		.container, .container-lg, .container-xl {
			width: unset;
			max-width: unset;
			margin: 0;
			padding: 0 2em;
		}
		@media (min-width: 768px) {
			.wiki-rightbar {
			width: unset !important;
			}
		}
	`);
})();

Mottie avatar May 31 '20 14:05 Mottie

Actually, try this userscript... it really only needs a minimal amount of css to work:

It works as-is for me. 😍

HenryGessau avatar Feb 26 '23 02:02 HenryGessau