User:Wugapodes/Capricorn
Capricorn | |
---|---|
♑ | |
![]() Capricorn interface during category selection | |
Description | Editing redirects |
Author(s) | Keφr, modified by Sam Sailor, and Wugapodes |
Status | Stable |
Updated | 26 October 2019 |
Browser support | Google Chrome |
Skin support | Monobook Vector |
Source |
Capricorn is a user script to assist in categorizing redirects. It is the successor to Sam Sailor's Sagittarius+ which was a modified version of Keφr's sagittarius. The script has been updated to support (nearly) all redirect category templates in Category:Redirect templates as well as allow new page reviewers to mark redirects as patrolled. The organization of templates in the user interface has also been changed to accomodate the additional redirect category templates now supported. For more information on a given template, see Wikipedia:Template messages/Redirect pages which is linked to from the bottom right of the interface as WP:TMR.
Installation instructions[edit]
Put the line:
mw.loader.load('//en.wikipedia.org/w/index.php?title=User:Wugapodes/Capricorn.js&action=raw&ctype=text/javascript');
in your common.js page, save the page, and bypass your browser cache.
Usage[edit]
After installing, when you go to a redirect page, a green box with a text field and check boxes will appear. Editing the text field will change the target of the redirect. After selecting the checkboxes of redirect category templates you wish to add, click the save button at the bottom left of the green box. This will save the page with an automated edit summary, retarget if needed, and add the templates in the {{redirect category shell}} template. Users with the New pages reviewer user right can additionally select the "Mark as patrolled" box to mark the page as patrolled in addition to making the categorization edits.
Limitations[edit]
- Language codes should be added manually to {{R from alternative language}}.
- Former target needs to be added manually to {{R avoided double redirect}}.
- The "Mark as patrolled" box appears regardless of page review status. If the page cannot be reviewed, whether due to lack of permissions or the page not being in the new pages feed, the edits will still be saved.
Bugs[edit]
- Redirects to anchors are not recognized, so it will throw an error at first. Click save again to proceed anyway.
Feedback and bugs[edit]
You can report bugs by adding to this section or by leaving a message on my talk page.
- Cannot parse {{R to TV episode list entry}} or {{R from merge}} (might be fixed in upcoming release)
- UI appears when looking at a diff of a redirect
- Feature request: clickable link to redirect target (ideally near the top of the page)
To do[edit]
- {{r from alternative language}}
- Support adding language codes
- When adding redirect to page with this template populated with language codes, the script adds a new Rcat shell, which it should not do
- The script still runs of when viewing diffs (as you already know). This can be fixed by not running the script when the url contains
&diff
in the query string. - Implement a search bar, so it would only show matching checkboxes and presumably removes the headings.
- Add a save button near the top (after the redirectText input area)
- Have a button in the top right corner to hide/show the UI.
- Add an option to the drop-down menu when page is not a redirect
Source files[edit]
- User:Wugapodes/Capricorn.js – Production version
- User:Wugapodes/CapricornDev.js – Development version; highly unstable
- User:Wugapodes/Capricorn.css – Style sheet for the interface
- User:Wugapodes/Capricorn/RedirectTemplates.json – JSON file with Rcat templates, labels, and groupings
- User:Wugapodes/Capricorn/RedirectAliases.json – Aliases for Rcat templates
Userbox[edit]
Code | Result | |||
---|---|---|---|---|
{{User:BlankpopsiclesilviaASHs4/Userboxes/User Capricorn}} |
|
Usage |
Adding this template to your userpage will populate Category:Wikipedians who use Capricorn.