User:Daniel Quinlan/Scripts/Rescaled

Rescaled
AuthorDaniel Quinlan
StatusBeta
Updated3 September 2025
SourceRescaled.js

The Rescaled script helps administrators clean up orphaned non-free file revisions that have been replaced by a lower-resolution revision per WP:F5 with a single button click.

Features

[edit]
  • Adds buttons to delete orphaned non-free file revisions with a single click.
  • Shows pending and completed deletions in the file table and provides notifications for other actions and errors.
  • Automatically removes templates that are no longer needed from the file description.
  • Displays megapixel counts for each revision to assist in decision-making.

Usage

[edit]
  • Rescaled buttons appear next to the revision deletion controls in the file history table when undeleted old revisions exist.
  • Clicking the button deletes older revisions and removes {{Orphaned non-free revisions}} and {{Non-free reduced}} templates from the file description (pending deletions are marked with a canvas effect, deleted revisions are marked with red strikeout, and a notification summarizes any changes to the file description).

Installation

[edit]

To install the Rescaled.js script, follow these steps:

  1. In your preferences, go to Preferences → Gadgets. At the bottom of the "Advanced" section, click the "Install scripts without having to manually edit JavaScript files (documentation)" checkbox, then click the "Save" button.
  2. Return to this page and click the blue "Install" button.

Alternatively, you can manually install it by adding the following code to your common.js file:

{{subst:iusc|User:Daniel Quinlan/Scripts/Rescaled.js}}

Credits

[edit]

This script is based on User:Legoktm/rescaled.js via User:Ronhjones/rescaled.js. It has since been rewritten, so any issues should be attributed to me.