Skip to content

Overhaul the mods list screen#3073

Open
sciwhiz12 wants to merge 50 commits into
neoforged:26.1.xfrom
sciwhiz12:feat/26.1/new-mods-list-screen
Open

Overhaul the mods list screen#3073
sciwhiz12 wants to merge 50 commits into
neoforged:26.1.xfrom
sciwhiz12:feat/26.1/new-mods-list-screen

Conversation

@sciwhiz12
Copy link
Copy Markdown
Member

@sciwhiz12 sciwhiz12 commented Apr 7, 2026

This PR overhauls the mods list screen with better graphics, better accessibility, and extensibility for mod developers.

The following is a visual side-by-side for comparison between the old mod lists screen and the new mod lists screen:

Status quo This PR
The original mods list screen

Taken from 26.1.1.8-beta.

The overhauled mods list screen

Last updated: 12:23AM UTC+8, Apr 28


TO-DO list:

  • Re-add support for the update checker.
    • Version check icon on the mods list screen.
    • Entry in the info panel if a new version was found (perhaps before the description).
    • Perhaps a new action button, showing a dialog box of sorts.
  • Consider if an extension point is best for the mod display info.
  • Consider if URL is better than URI.
  • See if logoBlur can be reimplemented. Not at the moment.
  • Javadocs.
  • Create PR to FML to update the hardcoded in-dev Minecraft mod info.
  • Remove TestingResources and associated data.

Noteworthy changes

Here is a non-exhaustive list of noteworthy changes:

  • Simplified layout of the mod lists screen. The new layout is simplier and easier to understand, with the search and sort buttons both at the top sidebar above the mods list, and the three action buttons (Homepage, Issues, and Config) below the info panel.
  • Cleaner info panel. Unnecessary information was removed (child mods, mod load state), and the entry headers are de-emphasized in order to emphasize the actual mod information.
  • Icon support. Mods can now supply an icon for their mod, which is shown in the mod info panel, through the iconFile mod property.
  • Buttons for the homepage (displayUrl) and issues (issuesUrl) URLs. Previously, these were raw links in the info panel, which could not be clicked or even copied.
  • Display info extensibility. Mods can register the ModDisplayInfo extension point on their mod container to customize to some degree their entry on the mod list screen. The entries for the authors, license, credits, and description support full components, with hover events and click events working as expected.
  • Improved accessibility. The important elements in the mod info panel are focusable, which improves accessibility support for the narrator. The tab order goes: the search box and sort button, the mods list, the info panel, the action buttons panel, and the bottom buttons panel.

Modder-facing changes

The following newly-added properties to the neoforge.mods.toml are accessible to modders:

  • Under [[mods]]: iconFile as a path to a root resource or pack resource to a suitable icon. The icon is rendered as a 24px × 24px square. (Can also be specified at the top-level, like logoFile.)
  • At the top-level: licenseURL as a URL to a link for the associated license.

Logos (logoFile) and icons (iconFile) can be specified in any of three ways:

  • A plain path, such as neoforged_icon.png. This is interpreted as a root resource, under the root of the mod's JAR.
  • A pack ID and a path delimited by a #, such as mod/neoforge#neoforged_icon.png. This is interpreted as a root resource, under the root of the specified pack. (A mod JAR that contains abc has a pack ID of mod/abc; one that contains two mods xyz and fgh has a pack ID of mod/xyz,fgh.)
  • An identifier, such as neoforge:textures/gui/bigsquirr.png. This is interpreted as a pack resource, searched in the active resource packs.

Note

Due to a consequence of how logos are rendered, logoBlur no longer has effect.

Modders can supply a translation key of neoforge.screen.mods.info.description.<modid> for localizing their mod descriptions.

ModDisplayInfo extension point

For better customizability, modders can register a new extension point of ModDisplayInfo (via ModContainer#registerExtensionPoint) to customize the display of their mod's information. The defaults are available and extendible through DefaultModDisplayInfo.

Aside from the displayName component, all other components support both click events and hover events.

Examples of uses for ModDisplayInfo are: translatable components, colors, seasonal changes (Christmas, April Fools, Halloween, etc.), clickable links for other resources or authors' profiles, and so on.

Note

The search (or rather, 'filter') function of the mod list is case-insensitive and based on the display name of the mod display info. Therefore, modders are encouraged to not translate their display name, in order to provide a consistent searching experience.

This aligns the tab order of the button to the natural order
(left-right, top-down) of the buttons.
This overhaul has better visuals, better accessibility, and
extensibility for mods to customize their mod entry on the list screen.
@sciwhiz12 sciwhiz12 added enhancement New (or improvement to existing) feature or request 26.1 Targeted at Minecraft 26.1 labels Apr 7, 2026
@neoforged-pr-publishing
Copy link
Copy Markdown

neoforged-pr-publishing Bot commented Apr 7, 2026

  • Publish PR to GitHub Packages

Last commit published: 2ab33e5863b24e92f1408e7a6384cb1ebf3e103a - version: 26.1.2.110-beta-pr-3073-feat-26.1-new-mods-list-screen

PR Publishing

The artifacts published by this PR:

Repository Declaration

In order to use the artifacts published by the PR, add the following repository to your buildscript:

repositories {
    maven {
        name = "Maven for PR #3073" // https://github.com/neoforged/NeoForge/pull/3073
        url = uri("https://prmaven.neoforged.net/NeoForge/pr3073")
        content {
            includeModule("net.neoforged", "neoforge")
            includeModule("net.neoforged", "testframework")
        }
    }
}

MDK installation

In order to setup a MDK using the latest PR version, run the following commands in a terminal.
The script works on both *nix and Windows as long as you have the JDK bin folder on the path.
The script will clone the MDK in a folder named NeoForge-pr3073.
On Powershell you will need to remove the -L flag from the curl invocation.

mkdir NeoForge-pr3073
cd NeoForge-pr3073
curl -L https://prmaven.neoforged.net/NeoForge/pr3073/net/neoforged/neoforge/26.1.2.110-beta-pr-3073-feat-26.1-new-mods-list-screen/mdk-pr3073.zip -o mdk.zip
jar xf mdk.zip
rm mdk.zip || del mdk.zip

To test a production environment, you can download the installer from here.

@neoforged-compatibility-checks
Copy link
Copy Markdown

neoforged-compatibility-checks Bot commented Apr 7, 2026

@sciwhiz12, this PR introduces breaking changes.
Fortunately, this project is currently accepting breaking changes, but if they are not intentional, please revert them.
Last checked commit: 2ab33e5863b24e92f1408e7a6384cb1ebf3e103a.

neoforge (:neoforge)

  • net/neoforged/neoforge/client/gui/widget/ModListWidget
    • ❗ API class no longer exists
  • net/neoforged/neoforge/client/gui/ModListScreen
    • ❗ API class no longer exists
  • net/neoforged/neoforge/client/gui/widget/ModListWidget$ModEntry
    • ❗ API class no longer exists

@Fuzss
Copy link
Copy Markdown

Fuzss commented Apr 7, 2026

Definitely looks like an improvement over the current screen, thanks!

One quick question: Is there any reason why A-Z is not the default sort order? I presume as with the old screen the default sorting is the internal mod loading order which imo doesn't have any benefit for this user-facing screen over A-Z sorting.

@sciwhiz12
Copy link
Copy Markdown
Member Author

One quick question: Is there any reason why A-Z is not the default sort order? I presume as with the old screen the default sorting is the internal mod loading order which imo doesn't have any benefit for this user-facing screen over A-Z sorting.

Hmmm. I've received quite a few suggestions to remove the default sorting method (which is, yes, a carryover from the old mod list screen and just the mod load order) and replace it with A-Z by default. Given the demand, I'll get rid of it and have A-Z and Z-A remain, with A-Z by default.

@KnightMiner
Copy link
Copy Markdown
Contributor

Load order seems like a useful thing to have for the sake of quick debug, as otherwise you have to dig through the logs for the same info. It makes sense having A-Z be default, but I think keeping load order around as an option would be helpful.

ApexModder added a commit to ApexStudios-Dev/FantasyFurniture that referenced this pull request Apr 8, 2026
@sciwhiz12
Copy link
Copy Markdown
Member Author

  1. Is there any reason why Mod ID, Version and Open Mods Folder aren't properly capitalized?

For the first two, I meant them to be additional information that was narratable and descriptive of their information. Upon a suggestion, I've removed them and left the mod ID and version plainly.

For the last one, the button was named as such since forever I believe. I've corrected it now.

2. Also have you considered using a default fallback mod icon instead of omitting the icon entirely if none is defined?

I briefly did consider it, but I decided not to because (a) I didn't want to populate the list with a lot of the same icon for mods that didn't bother to supply an icon, which is just visual noise to my eyes; (b) I didn't want to select such an icon; (c) I prefer having the full name be more visible in the case of having no icon.

It should be trivial to add a default icon though, since the icon supports loading any arbitrary texture (without animation, or at least I didn't add any explicit support so I'd assume animations aren't supported).

3. The Mods header looks like it takes up quite a lot of space which seems like it could maybe be better used by the elements below. Maybe it's worth removing the header entirely?

Done.

@sciwhiz12
Copy link
Copy Markdown
Member Author

Load order seems like a useful thing to have for the sake of quick debug, as otherwise you have to dig through the logs for the same info. It makes sense having A-Z be default, but I think keeping load order around as an option would be helpful.

I don't think it would be useful. I think it is rare that a modder would check the mod load order from the mods list screen, much less an end-user who likely are the common users of the mods list screen. Even so, the mod sort order is also available in the logs as you've said, so it is a quick check there or in the console to figure out the mod load order.

If it is wanted solely for the case of modders who may somehow need to reach that information conveniently, I could make it so it is available only if running in development.

@sciwhiz12 sciwhiz12 marked this pull request as ready for review May 16, 2026 05:17
@sciwhiz12
Copy link
Copy Markdown
Member Author

This PR is now ready for review. For users, you can use the PR-published installer to try this out in your local environments. No mods should be broken by this change.

ApexModder added a commit to ApexStudios-Dev/FantasyFurniture that referenced this pull request May 16, 2026
@FunctionalInterface
@ApiStatus.Internal
@VisibleForTesting
public interface ConfigurationScreenFactory {
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What's the use case of extracting this out into a functional interface? As far as I can tell, only the default "impl" is ever used.

@FunctionalInterface
@ApiStatus.Internal
@VisibleForTesting
public interface VersionCheckResultSupplier {
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What's the use case of extracting this out into a functional interface? As far as I can tell, only the default "impl" is ever used.

/// The logo is rendered with its original aspect ratio, bounded by the width of the info panel (ordinarily
/// {@value ModListScreen#INFO_PANEL_WIDTH} pixels) and a maximum height of {@value ModListScreen#LOGO_HEIGHT} pixels.
@Nullable
ImageResource logo(); // rendered as rectangle
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would prefer this and the associated mods.toml property to be called banner to make it more explicit what it's referring to and to disconnect it from the previous, rather ambiguous logo property (which should be deprecated).
Ideally the default implementations of icon() and this method would then fall back to the logo property if their respective primary property is absent and either both render said logo or check the aspect ratio to decide whether it should be used as an icon or banner.

import org.slf4j.Logger;

@ApiStatus.Internal
class ChangelogScreen extends Screen {
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do you have an example of what this screen and the link to it looks like? I currently don't have any mods using the update checker at hand.
I'm also not sure how useful this is considering the update checker is being put into question in general.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

26.1 Targeted at Minecraft 26.1 enhancement New (or improvement to existing) feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Mod descriptions are sometimes weirdly cut off in the mods menu.

4 participants