You will need to install a user script manager extension to install this script.
Based on the original script by LouCypher (https://greasyfork.org/en/users/4-loucypher) which can be found here: https://greasyfork.org/en/scripts/22-wikipedia-edit-1st-section
I have updated the script to the modern WikiPedia format. See the differences for yourself in the screenshots attached below.
I do not claim credit to any part of the script other than the few lines of the code that I have tweaked.