User:Anastrophe/BuildUrOwn
Appearance
Here's the steps to make your own default summaries. Yes, there are a lot of steps, but they're relatively simple and straightforward.
- Open your user page in a new browser tab.
- In the address bar of your browser, append a filename to it, it can be called anything, but in the form of, for example:
- https://en.wikipedia.org/wiki/User:Iljhgtn/MyEditSummaries.js
- The file name doesn't matter, just so long as it ends in ".js" - you could call it zoom.js, myfix.js, whatever.
- You'll be presented with a page advising that the file doesn't exist, with a link to " Start the User:Iljhgtn/zoom.js (or whatever) page.
- Click that link. You'll get an edit page similar to, but not quite the same as usual. It's designed for 'coding'.
- In another tab in your browser, visit this specific URL - ignore that it says 'edit', it is protected from editing:
- https://en.wikipedia.org/enwiki/w/index.php?title=User:Deisenbe/Gadget-defaultsummaries.js&action=edit
- Recommend confirming for yourself that this is the current source used for the 'edit summaries' gadget.
- Click anywhere within the numbered lines, hit 'ctrl-a' to select it, then 'ctrl-c' to copy it.
- Go to the tab with your new file, and then 'ctrl-v' paste the text into the empty editing box.
- The only text that matters here is within those first 43 or so lines. You'll see, for example,
- To 'break' out that first option, just copy and paste it three times beneath then edit the duplicated lines 'down':
- 'Spelling correction',
- 'Grammar correction',
- 'Punctuation correction',
- 'Typographical correction',
- 'Spelling correction',
- Or you can select any of the listed lines you want as your source, then copy/paste/modify it.
- The most critical aspect in making these changes to be certain you retain the single apostrophe at the start of a line and the apostrophe-comma at the end of a line, EXCEPT for the last line of choices, which does NOT end in a comma. For example:
- 'alpha',
- 'beta',
- 'gamma',
- 'delta',
- 'epsilon' <--Last line before closing bracket, no comma
- ],
- 'alpha',
- Save the page once you are satisfied. Wouldn't hurt to keep the file open in the editor for now.
- Next, open the page for "common.js", which may already exist and which may or may not have anything in it yet, for example:
- Edit the file, and at the bottom of it, add:
- importScript('User:Iljhgtn/MyDefaultsummaries.js'); <--Substitute the name you gave your script
- Save the file, but leave the edit window open, in case you made any mistakes.
- Open your personal 'sandbox', for example,
- And try editing it - and see if your edit summary options are listed correctly. You may need to clear the cache in your browser, typically 'ctrl-F5' on your keyboard, or hold 'ctrl' and click the refresh button in the address bar.
- If all appears okay, You're done. If the edit page is screwed up in any way - doesn't render properly, throws errors, etc, then in the editor for common.js, just put a couple of forward slashes - "//" at the beginning of the line for your script, and save it, so that you aren't prevented from further editing.
- And, if it is broken, it may need 'further intervention' to make it functional. You can just reply on my talk page and we'll see if we can fix it, and I'll get back to you when I can. Note that your 'common.js' file and the script you created cannot be edited by anyone other than yourself or an administrator.
Good luck.