[PR #1243] [MERGED] Launcher mod browser: project pages, search filters, project icons and gallery #3449

Closed
opened 2026-11-03 04:09:36 +07:00 by bsakaguchi · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/horizon-rust/horizon/pull/1243
Author: @ludovic111
Created: 10/22/2026
Status: ✅ Merged
Merged: 10/22/2026
Merged by: @ludovic111

Base: main ← Head: feat/modbrowser-project-page


📝 Commits (9)

  • da996b9 port-pack: check one mod jar (Works, Partly, Doesn't run) from its content and classes
  • 4a350bb port-pack carry: leave out recipes for items it didn't declare
  • 3530560 Launcher: Java mods in the mod browser, checked before install; Modpacks moves into Mods
  • a3f81f3 Launcher: test a Java mod's install, dependencies, id clash and removal offline
  • b8f7924 Mod browser: CurseForge is coming soon
  • f539986 Launcher mod browser: project pages, search filters, project icons and gallery
  • 9ae041c Merge origin/main into feat/modbrowser-java-verdicts
  • a5d68dc Merge feat/modbrowser-java-verdicts (now with main) into feat/modbrowser-java-launcher
  • 69887b8 Merge feat/modbrowser-java-launcher (now with main) into feat/modbrowser-project-page

📊 Changes

26 files changed (+3490 additions, -178 deletions)

View changed files

📝 crates/horizon-port-pack/src/carry.rs (+89 -0)
➕ crates/horizon-port-pack/src/check.rs (+411 -0)
➕ crates/horizon-port-pack/src/classes.rs (+642 -0)
📝 crates/horizon-port-pack/src/lib.rs (+2 -0)
📝 crates/horizon-port-pack/src/main.rs (+16 -1)
📝 docs/mod-browser.md (+90 -30)
📝 docs/modpacks.md (+16 -0)
📝 launcher/Cargo.toml (+1 -1)
📝 launcher/README.md (+5 -5)
📝 launcher/src/browser.rs (+81 -18)
📝 launcher/src/browser/curseforge.rs (+6 -2)
➕ launcher/src/browser/details.rs (+368 -0)
➕ launcher/src/browser/images.rs (+265 -0)
📝 launcher/src/browser/installed.rs (+33 -10)
📝 launcher/src/browser/installed/tests.rs (+83 -1)
➕ launcher/src/browser/java.rs (+340 -0)
📝 launcher/src/browser/modrinth.rs (+49 -14)
📝 launcher/src/browser/tests.rs (+58 -4)
📝 launcher/src/cli.rs (+71 -9)
📝 launcher/src/main.rs (+2 -4)

...and 6 more files

📄 Description

🤖 Opened by Ludovic's AI agent (Claude), not by Ludovic himself.

Ludovic's asks for the mod browser (brief modbrowser-java-1, coordinator follow-ups): project pages inside the launcher, search filters, real project icons and gallery images, and source logos. Stacked on #1242 (Java mods in the browser); this diff is against its branch.

What

  • Project page inside the launcher (mods_project.rs, data in browser/details.rs). A result's title or icon opens it, GD-Launcher style, in place of the results: icon, authors (owner first), downloads, followers, last update, licence, source, the verdict (for a Java mod, what ports and what doesn't) with Install / Import, links (source, issues, wiki, Discord, donations; https:// only, opened in the system browser), and three tabs: Description (the project's Markdown through the launcher's existing renderer), Gallery (featured first), Versions (date, loaders, game versions, file, size, and the verdict of any version already checked). Modrinth: GET /project/{id}, /project/{id}/members, /project/{id}/version.
  • Filters above the results: sort (relevance, downloads, follows, newest, updated) and, under Filters, loader, game version, environment (client, server; Modrinth's client_side/server_side facets) and categories, with the values Modrinth lists for the kind (/tag/category, /tag/loader, /tag/game_version, fetched once per run). A picked loader or version replaces the default; a version other than 26.3 checks the newest 1.21+ file, like Show everything. CurseForge support is coming soon; its source already maps the sort and the game version.
  • Real icons for every kind (mods, modpacks, resource packs, shader packs): each result's icon_url, and the gallery images, fetched at run time by browser/images.rs: HTTPS only, from cdn.modrinth.com (and CurseForge's media.forgecdn.net, edge.forgecdn.net), at most 8 MB, decoded with pixel limits, scaled (icons 128 px, gallery 960 px), stored as PNG in mod-browser/images/ (sha1 of the URL), the folder kept under 128 MB by dropping the oldest. Four fetch workers. A plate with the project's initial stands in while an icon loads or when it fails. No third-party image is committed.
  • Vanilla is marked by a grass block drawn at run time from the player's own prepared game files (grass_block_top/side*.png, tinted plains green, isometric) and cached as mod-browser/images/grass-block.png under the game folder. Nothing of Mojang's is in the repo or the launcher.

Source logos (Modrinth's brand guidelines)

Modrinth's logo is not shipped. Modrinth's own repository says its branding is all rights reserved: "the use of Modrinth branding elements, including but not limited to the wrench-in-labyrinth logo, ... is strictly prohibited without explicit written permission from Rinth, Inc." (packages/assets/COPYING.md in modrinth/code), and the Modrinth terms require prior written permission to use its marks. The page head names the source in text ("from Modrinth"), where a logo would go once Rinth, Inc. agrees. CurseForge support, and so its logo, is coming soon. Ludovic confirmed on 2026-10-22: no Modrinth logo, real project icons yes.

Measured (Mac mini)

  • Opening a page: the three Modrinth calls for Macaw's Fences took 0.24 s (project, 10 KB), 0.26 s (members) and 0.43 s (versions, 313 KB), run in the background; the page draws as each arrives.
  • Icons: one 128 px PNG per project, a few KB each, fetched once and then read from disk.
  • The game is untouched: no load-time change.

For design-gaming-1 (the restyle)

Data and logic are apart from drawing: browser::details (Details, Filters, Sort, Environment, Tags, Image, Link) and browser::images (fetch, cache, grass_block) have no UI code. mods_project.rs draws them only with the launcher's existing shared components (button, segments, plate, caps, index_row, notice, text, the Markdown renderer) and no new colours or sizes, so the restyle applies as is; its functions (mods_project_page, mods_filters, mods_icon, vanilla_icon) are the pieces to restyle or move. Shared files touched minimally: main.rs (1 line: the module), mods_page.rs (filters passed to the query, the page shown in place of results, an icon per row).

Self-check

  • cargo fmt --check, cargo clippy --features gpui/runtime_shaders --all-targets: clean
  • cargo test --features gpui/runtime_shaders (launcher): all pass (new: a Modrinth page parsed with only https links and featured gallery first, tags per project type, default sorts, only the source's image servers, images scaled/stored/pruned under the cap, a grass block drawn from faces)
  • Screenshots: not possible this session, the Mac mini's screen stayed locked (CGSSessionScreenIsLocked true).

Needs Ludovic

Nothing. Ludovic chose no Modrinth logo (2026-10-22). Permission from Rinth, Inc. would be needed only if that changes.

🤖 Generated with Claude Code


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/horizon-rust/horizon/pull/1243 **Author:** [@ludovic111](https://github.com/ludovic111) **Created:** 10/22/2026 **Status:** ✅ Merged **Merged:** 10/22/2026 **Merged by:** [@ludovic111](https://github.com/ludovic111) **Base:** `main` ← **Head:** `feat/modbrowser-project-page` --- ### 📝 Commits (9) - [`da996b9`](https://github.com/horizon-rust/horizon/commit/da996b9fd13e02ab3e758393b6d428d4ef6f07d0) port-pack: check one mod jar (Works, Partly, Doesn't run) from its content and classes - [`4a350bb`](https://github.com/horizon-rust/horizon/commit/4a350bb0a03c64b34245ddd5e3f526de305988f2) port-pack carry: leave out recipes for items it didn't declare - [`3530560`](https://github.com/horizon-rust/horizon/commit/35305605819cece46b2c53bdc94cc9de5151bd80) Launcher: Java mods in the mod browser, checked before install; Modpacks moves into Mods - [`a3f81f3`](https://github.com/horizon-rust/horizon/commit/a3f81f3a30ec54d2cb84e806334db2db8a14684b) Launcher: test a Java mod's install, dependencies, id clash and removal offline - [`b8f7924`](https://github.com/horizon-rust/horizon/commit/b8f79247b865c2a4bba9d5e65803e280f581ceca) Mod browser: CurseForge is coming soon - [`f539986`](https://github.com/horizon-rust/horizon/commit/f53998674de95895558b99e00f572175293db3e0) Launcher mod browser: project pages, search filters, project icons and gallery - [`9ae041c`](https://github.com/horizon-rust/horizon/commit/9ae041ccd3a2e674616503eae5008a5125d61496) Merge origin/main into feat/modbrowser-java-verdicts - [`a5d68dc`](https://github.com/horizon-rust/horizon/commit/a5d68dc8900d0d01806e606e1eb9bd9d69875e06) Merge feat/modbrowser-java-verdicts (now with main) into feat/modbrowser-java-launcher - [`69887b8`](https://github.com/horizon-rust/horizon/commit/69887b87d12220903adc85400bc603a2afef6d9a) Merge feat/modbrowser-java-launcher (now with main) into feat/modbrowser-project-page ### 📊 Changes **26 files changed** (+3490 additions, -178 deletions) <details> <summary>View changed files</summary> 📝 `crates/horizon-port-pack/src/carry.rs` (+89 -0) ➕ `crates/horizon-port-pack/src/check.rs` (+411 -0) ➕ `crates/horizon-port-pack/src/classes.rs` (+642 -0) 📝 `crates/horizon-port-pack/src/lib.rs` (+2 -0) 📝 `crates/horizon-port-pack/src/main.rs` (+16 -1) 📝 `docs/mod-browser.md` (+90 -30) 📝 `docs/modpacks.md` (+16 -0) 📝 `launcher/Cargo.toml` (+1 -1) 📝 `launcher/README.md` (+5 -5) 📝 `launcher/src/browser.rs` (+81 -18) 📝 `launcher/src/browser/curseforge.rs` (+6 -2) ➕ `launcher/src/browser/details.rs` (+368 -0) ➕ `launcher/src/browser/images.rs` (+265 -0) 📝 `launcher/src/browser/installed.rs` (+33 -10) 📝 `launcher/src/browser/installed/tests.rs` (+83 -1) ➕ `launcher/src/browser/java.rs` (+340 -0) 📝 `launcher/src/browser/modrinth.rs` (+49 -14) 📝 `launcher/src/browser/tests.rs` (+58 -4) 📝 `launcher/src/cli.rs` (+71 -9) 📝 `launcher/src/main.rs` (+2 -4) _...and 6 more files_ </details> ### 📄 Description > 🤖 Opened by Ludovic's AI agent (Claude), not by Ludovic himself. Ludovic's asks for the mod browser (brief modbrowser-java-1, coordinator follow-ups): project pages inside the launcher, search filters, real project icons and gallery images, and source logos. Stacked on #1242 (Java mods in the browser); this diff is against its branch. ## What - **Project page inside the launcher** (`mods_project.rs`, data in `browser/details.rs`). A result's title or icon opens it, GD-Launcher style, in place of the results: icon, authors (owner first), downloads, followers, last update, licence, source, the verdict (for a Java mod, what ports and what doesn't) with **Install** / **Import**, links (source, issues, wiki, Discord, donations; `https://` only, opened in the system browser), and three tabs: **Description** (the project's Markdown through the launcher's existing renderer), **Gallery** (featured first), **Versions** (date, loaders, game versions, file, size, and the verdict of any version already checked). Modrinth: `GET /project/{id}`, `/project/{id}/members`, `/project/{id}/version`. - **Filters** above the results: sort (relevance, downloads, follows, newest, updated) and, under **Filters**, loader, game version, environment (client, server; Modrinth's `client_side`/`server_side` facets) and categories, with the values Modrinth lists for the kind (`/tag/category`, `/tag/loader`, `/tag/game_version`, fetched once per run). A picked loader or version replaces the default; a version other than 26.3 checks the newest 1.21+ file, like **Show everything**. CurseForge support is coming soon; its source already maps the sort and the game version. - **Real icons for every kind** (mods, modpacks, resource packs, shader packs): each result's `icon_url`, and the gallery images, fetched at run time by `browser/images.rs`: HTTPS only, from `cdn.modrinth.com` (and CurseForge's `media.forgecdn.net`, `edge.forgecdn.net`), at most 8 MB, decoded with pixel limits, scaled (icons 128 px, gallery 960 px), stored as PNG in `mod-browser/images/` (sha1 of the URL), the folder kept under 128 MB by dropping the oldest. Four fetch workers. A plate with the project's initial stands in while an icon loads or when it fails. No third-party image is committed. - **Vanilla** is marked by a grass block drawn at run time from the player's own prepared game files (`grass_block_top/side*.png`, tinted plains green, isometric) and cached as `mod-browser/images/grass-block.png` under the game folder. Nothing of Mojang's is in the repo or the launcher. ## Source logos (Modrinth's brand guidelines) Modrinth's logo is **not** shipped. Modrinth's own repository says its branding is all rights reserved: "the use of Modrinth branding elements, including but not limited to the wrench-in-labyrinth logo, ... is strictly prohibited without explicit written permission from Rinth, Inc." ([`packages/assets/COPYING.md` in modrinth/code](https://github.com/modrinth/code/blob/main/packages/assets/COPYING.md)), and the [Modrinth terms](https://modrinth.com/legal/terms) require prior written permission to use its marks. The page head names the source in text ("from Modrinth"), where a logo would go once Rinth, Inc. agrees. CurseForge support, and so its logo, is coming soon. Ludovic confirmed on 2026-10-22: no Modrinth logo, real project icons yes. ## Measured (Mac mini) - Opening a page: the three Modrinth calls for Macaw's Fences took 0.24 s (project, 10 KB), 0.26 s (members) and 0.43 s (versions, 313 KB), run in the background; the page draws as each arrives. - Icons: one 128 px PNG per project, a few KB each, fetched once and then read from disk. - The game is untouched: no load-time change. ## For design-gaming-1 (the restyle) Data and logic are apart from drawing: `browser::details` (`Details`, `Filters`, `Sort`, `Environment`, `Tags`, `Image`, `Link`) and `browser::images` (fetch, cache, `grass_block`) have no UI code. `mods_project.rs` draws them only with the launcher's existing shared components (`button`, `segments`, `plate`, `caps`, `index_row`, `notice`, `text`, the Markdown renderer) and no new colours or sizes, so the restyle applies as is; its functions (`mods_project_page`, `mods_filters`, `mods_icon`, `vanilla_icon`) are the pieces to restyle or move. Shared files touched minimally: `main.rs` (1 line: the module), `mods_page.rs` (filters passed to the query, the page shown in place of results, an icon per row). ## Self-check - `cargo fmt --check`, `cargo clippy --features gpui/runtime_shaders --all-targets`: clean - `cargo test --features gpui/runtime_shaders` (launcher): all pass (new: a Modrinth page parsed with only `https` links and featured gallery first, tags per project type, default sorts, only the source's image servers, images scaled/stored/pruned under the cap, a grass block drawn from faces) - Screenshots: not possible this session, the Mac mini's screen stayed locked (`CGSSessionScreenIsLocked` true). ## Needs Ludovic Nothing. Ludovic chose no Modrinth logo (2026-10-22). Permission from Rinth, Inc. would be needed only if that changes. 🤖 Generated with [Claude Code](https://claude.com/claude-code) --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
bsakaguchi 2026-11-03 04:09:36 +07:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
horizon-rust/horizon#3449
No description provided.