ChatGPT responsive + customizations

ChatGPT website is more suitable for wide screens.

За да инсталирате този скрипт, трябва да имате инсталирано разширение като Tampermonkey, Greasemonkey или Violentmonkey.

За да инсталирате този скрипт, трябва да инсталирате разширение, като например Tampermonkey .

За да инсталирате този скрипт, трябва да имате инсталирано разширение като Tampermonkey или Violentmonkey.

За да инсталирате този скрипт, трябва да имате инсталирано разширение като Tampermonkey или Userscripts.

За да инсталирате скрипта, трябва да инсталирате разширение като Tampermonkey.

За да инсталирате този скрипт, трябва да имате инсталиран скриптов мениджър.

(Вече имам скриптов мениджър, искам да го инсталирам!)

За да инсталирате този стил, трябва да инсталирате разширение като Stylus.

За да инсталирате този стил, трябва да инсталирате разширение като Stylus.

За да инсталирате този стил, трябва да инсталирате разширение като Stylus.

За да инсталирате този стил, трябва да имате инсталиран мениджър на потребителски стилове.

За да инсталирате този стил, трябва да имате инсталиран мениджър на потребителски стилове.

За да инсталирате този стил, трябва да имате инсталиран мениджър на потребителски стилове.

(Вече имам инсталиран мениджър на стиловете, искам да го инсталирам!)

/* ==UserStyle==
@name           ChatGPT responsive + customizations
@version        1.1.0
@description    ChatGPT website is more suitable for wide screens.
@author         BreatFR (https://breat.fr)
@namespace      https://gitlab.com/breatfr
@homepageURL    https://gitlab.com/breatfr/chatgpt
@supportURL     https://discord.gg/Q8KSHzdBxs
@license        AGPL-3.0-or-later; https://www.gnu.org/licenses/agpl-3.0.txt
@preprocessor   stylus

@var    checkbox    chatmode 		"Chat mode"			1
@var    text        fontsize        "Custom font size"  1.2rem
@var    checkbox    hidechatgptplus "Hide ChatGPT plus"	1
@var	checkbox	hidescrollbars	"Hide scrollbars"	1
@var    checkbox    widemode        "Wide mode"         1
==/UserStyle== */

/* === Credits ===
Website         https://breat.fr
Bluesky			https://bsky.app/profile/breatfroff.bsky.social
facebook        https://www.facebook.com/breatfroff
mastodon        https://mastodon.social/@breat_fr
telegram        https://t.me/breatfr
vk              https://vk.com/breatfroff
X (twitter)     https://x.com/breatfroff
=== Credits === */

@-moz-document domain("chatgpt.com") {
/* =============================================
    ChatGPT
============================================= */
    /* Versions */
    :root {
        --themeversion: 'Theme v1.1.0 by BreatFR (https://breat.fr)';
        --install1: ' usercssjs.breat.fr ';
        --install2: ' gitlab.com/breatfr/chatgpt';
        --support1: ' ko-fi.com/breatfr ';
        --support2: ' paypal.me/breat';
    }

    @media (min-width: 900px) {
		body::after,
		body::before {
			align-items: center;
            background: linear-gradient(88.55deg, rgb(139, 109, 255) 22.43%, rgb(254, 132, 132) 92.28%);
            background-clip: text;
            -webkit-background-clip: text;
            color: transparent;
			display: flex;
            font-family: inherit;
            font-size: 1.2rem;
			height: 60px;
			line-height: 1.5;
            pointer-events: none;
            position: fixed;
            text-align: center;
			top: 0;
            width: auto;
			z-index: 9999;
		}
		
		html:has(div[style*="width:var(--sidebar-width);"]) body::before,
        html:has(div[style*="width: var(--sidebar-width);"]) body::before {
            content: var(--themeversion);
			left: 25%;
            white-space: wrap;
        }
		html:has(div[style*="width:var(--sidebar-rail-width);"]) body::before,
		html:has(div[style*="width: var(--sidebar-rail-width);"]) body::before {
			content: var(--themeversion);
			left: 15%;
            white-space: wrap;
        }
    
		body::after {
			content: 'Install: ' url("https://gitlab.com/breatfr/kindroid/-/raw/main/images/icon_breat.fr.png") var(--install1) url("https://gitlab.com/breatfr/kindroid/-/raw/main/images/icon_gitlab.png") var(--install2) '\ASupport me: ' url("https://gitlab.com/breatfr/kindroid/-/raw/main/images/icon_ko-fi.png") var(--support1) url("https://gitlab.com/breatfr/kindroid/-/raw/main/images/icon_paypal.png") var(--support2);
			right: 22%;
			white-space: pre-line;
		}
	}
	/* Custom font size */
	#prompt-textarea * {
		font-size: fontsize !important;
		line-height: 1.5 !important;
	}
	
	#stage-slideover-sidebar {
		border: 0 !important;
	}
    
    if hidechatgptplus {
		header > div:nth-of-type(1) {
			display: none;
		}
    }
	
	if hidescrollbars {
		* {
            scrollbar-width: none !important;
            -ms-overflow-style: none !important;
            -moz-overflow-style: none !important;
            -webkit-overflow-style: none !important;
        }    
        ::-webkit-scrollbar {
            display: none !important;
            width: 0 !important;
        }
	}
	
	if widemode {
		header {
			background: #181818;
			height: 60px;
			max-height: 60px;
			pointer-events: auto;
			position: fixed;
			right: 0;
			top: 0;
			max-width: 100%;
			width: 100%;
		}
	}
}

@-moz-document url-prefix("https://chatgpt.com/apps") {
/* =============================================
    ChatGPT Applications
============================================= */
	if widemode {
		:root {
			--container-4xl: 100%
		}
		
		main > div:nth-of-type(3) {
			margin-top: 0;
		}
	}
}

@-moz-document url-prefix("https://chatgpt.com/c/") {
/* =============================================
    ChatGPT Chats
============================================= */
	/* Custom font size */
	[data-message-author-role="assistant"] *,
	[data-message-author-role="user"] * {
		font-size: fontsize !important;
		line-height: 1.5 !important;
	}
	
	div:has(> article) {
		margin-top: 60px;
	}
	
    if chatmode {
        :root {
			--user-chat-width: 100%;
		}
		[data-message-author-role="assistant"],
		[data-message-author-role="user"] {
			max-width: 80% !important;
			width: 80% !important;
		}
		[data-message-author-role="user"] {
			margin-left: auto;
		}
    }
	
    if widemode {
		:root {
			--user-chat-width: 100%;
		}
		[data-message-author-role="assistant"],
		[data-message-author-role="user"] {
			max-width: 100% !important;
		}
		[data-message-author-role="assistant"] div {
			width: 100%;
		}
        [class*="[--thread-content-max-width:40rem]"] {
			--thread-content-max-width: 100% !important;
		}	
		article > div,
 		#thread-bottom > div {
			padding: 2em;
		}
		
		div:has(>article) {
			padding-bottom: 0 !important;
		}
        
        pre > div > div:nth-of-type(3) {
            box-sizing: border-box !important;
            max-width: 100% !important;
            overflow: hidden !important;
        }
        code.hljs {
            max-width: 100% !important;
            width: 100% !important;
            white-space: break-spaces !important;
        }
    }
}

@-moz-document url-prefix("https://chatgpt.com/codex") {
/* =============================================
    ChatGPT Codex
============================================= */
/* Versions */
	body::before {
		content: var(--themeversion);
		left: 15%;
		pointer-events: none;
		white-space: wrap;
	}
	
	if widemode {
		:root {
			--container-3xl: 97%
		}
	}
}

@-moz-document url-prefix("https://chatgpt.com/gpts") {
/* =============================================
    ChatGPT GPTs
============================================= */
	if widemode {
		:root {
			--container-3xl: 100%
		}
	}
}

@-moz-document url-prefix("https://chatgpt.com/images") {
/* =============================================
    ChatGPT Images
============================================= */
	if widemode {
		/* header {
			max-height: 60px;
			right: 0;
			top: 0;
			max-width: 100%;
		} */

		main > div > div > div {
			gap: 1em;
			padding-top: 2em;
		}
		
		main > div > div > div > div:nth-of-type(3) {
			max-width: 100%;
		}
	}
}