SharePoint - Enable List and Library Comments For Firefox

18/01/2024, 09:54:30

You will need to install an extension such as Tampermonkey, Greasemonkey or Violentmonkey to install this script.

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

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

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

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

You will need to install a user script manager extension to install this script.

(I already have a user script manager, let me install it!)

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.

You will need to install a user style manager extension to install this style.

You will need to install a user style manager extension to install this style.

You will need to install a user style manager extension to install this style.

(I already have a user style manager, let me install it!)

// ==UserScript==
// @name        SharePoint - Enable List and Library Comments For Firefox
// @namespace   Eliot Cole Scripts
// @match       https://*.sharepoint.com/*
// @grant       none
// @license     MIT
// @version     1.2
// @author      Eliot Cole
// @description 18/01/2024, 09:54:30
// @require     https://cdn.jsdelivr.net/npm/@violentmonkey/dom@2
// @require     https://cdn.jsdelivr.net/npm/jquery@3/dist/jquery.min.js
// ==/UserScript==

VM.observe(document.body, () => {
  // Find the target node
  const $node = $('.od-addNewCommentTextField-mentionableTextBox');

  if ($node.length) {
    $node.attr('contenteditable', 'true');

    // disconnect observer - This is disabled as if you disconnect you cannot enter more comments
    // return true;
  }
});