Resolving a glitch in the ChatGPT interface on Firefox using Tampermonkey
Published on 19th July 2025 Estimated Reading Time: 2 minutesIt may be caused either by a new version of Firefox or an update on the OpenAI side, but the ChatGPT prompt box lost its ability to show a cursor while I am entering text. The Ask anything text also disappeared. In Brave, all looked well, and it still persisted in clean Firefox sessions with no extensions loaded. Thus, it was a case of moving browser or getting a fix in Firefox.
The latter has not been needed because I found a fix of sorts. For that, I needed to install the Tampermonkey extension. Then, I could add a new script to override the behaviour that I was seeing:
// ==UserScript==
// @name ChatGPT Prompt Box Fix (Firefox)
// @namespace http://tampermonkey.net/
// @version 1.0
// @description Forces the ChatGPT prompt box textarea to remain visible in Firefox
// @author You
// @match https://chatgpt.com/*
// @grant none
// ==/UserScript==
(function () {
'use strict';
const waitForTextarea = () => {
const textarea = document.querySelector('textarea');
if (textarea) {
textarea.style.display = 'block';
const observer = new MutationObserver(() => {
if (textarea.style.display === 'none') {
console.log('Textarea display:none overridden');
textarea.style.display = 'block';
}
});
observer.observe(textarea, { attributes: true, attributeFilter: ['style'] });
} else {
setTimeout(waitForTextarea, 300); // Keep retrying until textarea appears
}
};
waitForTextarea();
})();
In short, this deals with a rogue display: none;
line in the CSS, which equally well could have been inserted by JavaScript from somewhere that I cannot track down. The extra code is executed within a self-contained function to prevent interference with other elements and is restricted to the ChatGPT domain, which avoids unwanted impacts on the display of other websites.
The first step is to search for the relevant element on the page, retrying at intervals if necessary. Once located, the element's visibility is ensured by explicitly setting its display property to block
. Continued monitoring of the element thwarts any dynamic attempts to hide it by changing its style. When such an action is detected, the script automatically overrides such changes to maintain its visibility, thereby ensuring consistent accessibility.
However, challenges with finding the affected element mean that I get the advisory text duplicated. Thus, I see two instances of Ask anything. However, that is a small price to pay for having a flashing cursor telling me where I am in the interface. Such is the nature of modern web coding that its complexity hinders debugging, thus posing the question as to why we are making such things so complicated in the first place.