The FilterDiff script improves the readability of Special:AbuseFilter version diffs.
- Collapses unmodified lines that are far from changes, similar to the context or unified diff formats.
- Provides toggle buttons to expand and collapse individual diff sections.
- Removes unnecessary item labels to reduce clutter and maximize diff space.
- Adds line numbers for clarity when some unmodified lines are hidden.
When a diff section is , a toggle button is displayed on the right side of its header to expand or collapse the section.
To install the FilterDiff.js script, follow these steps:
- 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.
- 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/FilterDiff.js}}
None.