Skip to content

feat: MOD-300 Servers modpack upload progress feedback #3711

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 4 commits into
base: main
Choose a base branch
from

Conversation

IMB11
Copy link
Member

@IMB11 IMB11 commented May 26, 2025

No description provided.

@IMB11 IMB11 added enhancement New feature or request web Relates to Modrinth.com web frontend labels May 26, 2025
@IMB11 IMB11 marked this pull request as ready for review May 29, 2025 11:39
@IMB11 IMB11 requested a review from Copilot May 29, 2025 11:39
Copy link

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This PR adds modpack upload progress feedback for servers by updating the modpack reinstall process and enhancing the user interface for upload feedback.

  • Updated the reinstallFromMrpack function to use XMLHttpRequest for tracking file upload progress and returning both a promise and an onProgress callback.
  • Enhanced the PlatformMrpackModal.vue component to display an animated progress bar and provide user notifications for missing file selection and upload errors.

Reviewed Changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.

File Description
apps/frontend/src/composables/pyroServers.ts Modified reinstallFromMrpack to use XMLHttpRequest with progress events and updated its type.
apps/frontend/src/components/ui/servers/PlatformMrpackModal.vue Introduced a progress bar with transition animations and revised error handling for uploads.
Comments suppressed due to low confidence (3)

apps/frontend/src/composables/pyroServers.ts:604

  • [nitpick] Consider using a more formal error message, such as 'upload cancelled', to improve clarity and maintain consistency with other error messages.
xhr.onabort = () => reject(new Error("[pyroservers] .mrpack u cancelled"));

apps/frontend/src/composables/pyroServers.ts:605

  • [nitpick] Consider using a more formal error message, such as 'upload timed out', to align with the application's error messaging style.
xhr.ontimeout = () => reject(new Error("[pyroservers] .mrpack u timed out"));

apps/frontend/src/components/ui/servers/PlatformMrpackModal.vue:222

  • [nitpick] Review the capitalization of error titles for consistency. Using 'Reinstall Failed' might be more consistent with other notifications.
title: "Reinstall failed",

Signed-off-by: IMB11 <[email protected]>
@IMB11 IMB11 requested a review from Prospector June 4, 2025 22:04
@IMB11
Copy link
Member Author

IMB11 commented Jun 4, 2025

LGTM

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request web Relates to Modrinth.com web frontend
Development

Successfully merging this pull request may close these issues.

1 participant